mirror of
https://github.com/ahmadk953/tasko.git
synced 2025-05-04 12:43:24 +00:00
Optimize performance and reduce bundle sizes
## AI Generated code and Descriptions Improve website performance and efficiency by reducing bundle sizes and implementing caching strategies. * **next.config.ts**: Add `compression` middleware to enable gzip compression for responses. * **Lazy Loading**: Implement lazy loading for images in `app/(platform)/(dashboard)/board/[boardId]/_components/board-update-image.tsx` using the `loading="lazy"` attribute. Add `react-lazyload` library for lazy loading components in `app/(platform)/(dashboard)/board/[boardId]/_components/list-item.tsx` and wrap list items with `LazyLoad` component. * **Database Query Optimization**: Optimize database queries in `actions/copy-card/index.ts`, `actions/copy-list/index.ts`, `actions/create-board/index.ts`, `actions/create-card/index.ts`, `actions/create-list/index.ts`, `actions/delete-board/index.ts`, `actions/delete-card/index.ts`, `actions/delete-list/index.ts`, `actions/stripe-redirect/index.ts`, `actions/update-board/index.ts`, `actions/update-card-order/index.ts`, `actions/update-card/index.ts`, and `actions/update-list/index.ts` by adding appropriate indexes and using `select` to fetch only required fields. * **Dependencies**: Update `package.json` to include `compression` and `react-lazyload` dependencies. --- For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/ahmadk953/tasko?shareId=XXXX-XXXX-XXXX-XXXX).
This commit is contained in:
parent
0abdc50358
commit
7578b189ef
17 changed files with 293 additions and 125 deletions
|
@ -40,6 +40,7 @@
|
|||
"@vercel/speed-insights": "^1.1.0",
|
||||
"class-variance-authority": "^0.7.1",
|
||||
"clsx": "^2.1.1",
|
||||
"compression": "^1.7.4",
|
||||
"date-fns": "^4.1.0",
|
||||
"dompurify": "^3.2.3",
|
||||
"lodash": "^4.17.21",
|
||||
|
@ -48,6 +49,7 @@
|
|||
"react": "^19.0.0",
|
||||
"react-day-picker": "^9.4.4",
|
||||
"react-dom": "^19.0.0",
|
||||
"react-lazyload": "^3.2.0",
|
||||
"sharp": "^0.33.5",
|
||||
"sonner": "^1.7.1",
|
||||
"stripe": "^17.4.0",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue