Introduce a centralized Zustand store and refactor app state out of App.tsx into src/store/appStore.ts. Modularize API surface by moving media/cast/settings/converters/types into src/lib/api/* and re-exporting from src/api.ts for backward compatibility. Replace inline route helpers with dedicated route components (MediaDetailRoute, CastDetailRoute, CategoryBrowseRoute) and wire CATEGORY_PATHS/PATH_TO_CATEGORY constants. Update AddMediaView UI (icons, layout) and adjust settings/category handling to use DEFAULT_SETTINGS and the store. Add zustand to package.json/package-lock.json and include a new React SKILL.md. Overall changes improve state management, API organization, and route/component separation for better maintainability and code-splitting.
44 lines
1.1 KiB
JSON
44 lines
1.1 KiB
JSON
{
|
|
"name": "react-example",
|
|
"private": true,
|
|
"version": "0.0.0",
|
|
"type": "module",
|
|
"scripts": {
|
|
"dev": "vite --port=3000 --host=0.0.0.0",
|
|
"build": "vite build",
|
|
"preview": "vite preview",
|
|
"clean": "rm -rf dist",
|
|
"lint": "tsc --noEmit"
|
|
},
|
|
"dependencies": {
|
|
"@base-ui/react": "^1.3.0",
|
|
"@fontsource-variable/geist": "^5.2.8",
|
|
"@google/genai": "^1.29.0",
|
|
"@tailwindcss/vite": "^4.1.14",
|
|
"@vitejs/plugin-react": "^5.0.4",
|
|
"class-variance-authority": "^0.7.1",
|
|
"clsx": "^2.1.1",
|
|
"dotenv": "^17.2.3",
|
|
"express": "^4.21.2",
|
|
"lucide-react": "^0.546.0",
|
|
"motion": "^12.38.0",
|
|
"react": "^19.0.0",
|
|
"react-dom": "^19.0.0",
|
|
"react-router-dom": "^7.14.0",
|
|
"shadcn": "^4.2.0",
|
|
"tailwind-merge": "^3.5.0",
|
|
"tw-animate-css": "^1.4.0",
|
|
"vite": "^6.2.0",
|
|
"zustand": "^5.0.12"
|
|
},
|
|
"devDependencies": {
|
|
"@types/express": "^4.17.21",
|
|
"@types/node": "^22.14.0",
|
|
"autoprefixer": "^10.4.21",
|
|
"tailwindcss": "^4.1.14",
|
|
"tsx": "^4.21.0",
|
|
"typescript": "~5.8.2",
|
|
"vite": "^6.2.0"
|
|
}
|
|
}
|