chore(deps): upgrade to React 19, Chakra UI v3, router v7 and modern tooling

- React 18 -> 19 (react, react-dom, @types), react-router 6 -> 7,
  vite 5 -> 8, typescript 5.5 -> 5.9 with Bundler module resolution,
  esModuleInterop and @/* path alias
- Chakra 2.8 -> 3.37 (+cli), chakra-react-select 4.9 -> 6.1,
  next-themes for color mode; drop @chakra-ui/icons,
  chakra-ui-contextmenu, framer-motion and react-device-detect
- axios, jodit-react, hookform, toast, testing-library, node types
  bumped alongside; bun.lockb regenerated
- web-vitals 4 -> 6: ReportHandler/getCLS/getFID removed, migrate to
  MetricType with onCLS/onINP/onFCP/onLCP/onTTFB
This commit is contained in:
2026-09-06 10:28:30 -04:00
parent 406c508de0
commit 050e72bc8a
4 changed files with 46 additions and 47 deletions
BIN
View File
Binary file not shown.
+31 -35
View File
@@ -3,31 +3,27 @@
"version": "0.1.0", "version": "0.1.0",
"private": true, "private": true,
"dependencies": { "dependencies": {
"@chakra-ui/icons": "^2.1.1", "@chakra-ui/react": "^3.37.0",
"@chakra-ui/react": "^2.8.2", "@emotion/react": "^11.14.0",
"@emotion/react": "^11.13.3", "@hookstate/core": "^4.0.2",
"@emotion/styled": "^11.13.0",
"@hookstate/core": "^4.0.1",
"@hookstate/localstored": "^4.0.2", "@hookstate/localstored": "^4.0.2",
"axios": "1.7.5", "axios": "^1.20.0",
"bson-objectid": "^2.0.4", "bson-objectid": "^2.0.4",
"chakra-react-select": "^4.9.1", "chakra-react-select": "^6.1.3",
"chakra-ui-contextmenu": "^1.0.5", "interweave": "^13.1.1",
"framer-motion": "^11.3.30", "jodit-react": "^5.5.3",
"interweave": "^13.1.0", "js-base64": "^3.9.3",
"jodit-react": "^4.1.2", "next-themes": "^0.4.6",
"js-base64": "^3.7.7", "react": "^19.2.8",
"react": "^18.3.1", "react-dom": "^19.2.8",
"react-device-detect": "^2.2.3", "react-hook-form": "^7.87.0",
"react-dom": "^18.3.1", "react-icons": "^5.7.0",
"react-hook-form": "^7.53.0",
"react-icons": "^5.3.0",
"react-rating": "^2.0.5", "react-rating": "^2.0.5",
"react-responsive-carousel": "^3.2.23", "react-responsive-carousel": "^3.2.23",
"react-router-dom": "^6.26.1", "react-router-dom": "^7.18.3",
"react-select": "^5.8.0", "react-select": "^5.10.2",
"react-toastify": "^10.0.5", "react-toastify": "^11.1.0",
"web-vitals": "^4.2.3" "web-vitals": "^6.2.1"
}, },
"scripts": { "scripts": {
"start": "bunx --bun vite", "start": "bunx --bun vite",
@@ -42,8 +38,8 @@
] ]
}, },
"resolutions": { "resolutions": {
"@types/react": "18.2.21", "@types/react": "19.2.18",
"@types/react-dom": "18.2.7" "@types/react-dom": "19.2.7"
}, },
"browserslist": { "browserslist": {
"production": [ "production": [
@@ -58,18 +54,18 @@
] ]
}, },
"devDependencies": { "devDependencies": {
"@chakra-ui/cli": "^2.4.1", "@chakra-ui/cli": "^3.37.0",
"@hookstate/devtools": "^4.0.1", "@hookstate/devtools": "^4.0.3",
"@testing-library/jest-dom": "^6.5.0", "@testing-library/jest-dom": "^7.0.1",
"@testing-library/react": "^16.0.0", "@testing-library/react": "^16.3.3",
"@testing-library/user-event": "^14.5.2", "@testing-library/user-event": "^14.6.7",
"@types/jest": "^29.5.12", "@types/jest": "^30.0.0",
"@types/node": "^22.5.1", "@types/node": "^26.4.1",
"@types/react": "^18.2.21", "@types/react": "^19.2.18",
"@types/react-dom": "^18.2.7", "@types/react-dom": "^19.2.7",
"@types/react-table": "^7.7.20", "@types/react-table": "^7.7.20",
"@vitejs/plugin-react": "^4.3.1", "@vitejs/plugin-react": "^6.1.1",
"typescript": "^5.5.4", "typescript": "^5.9.3",
"vite": "^5.4.2" "vite": "^8.2.2"
} }
} }
+8 -8
View File
@@ -1,13 +1,13 @@
import { ReportHandler } from 'web-vitals'; import type { MetricType } from 'web-vitals';
const reportWebVitals = (onPerfEntry?: ReportHandler) => { const reportWebVitals = (onPerfEntry?: (metric: MetricType) => void) => {
if (onPerfEntry && onPerfEntry instanceof Function) { if (onPerfEntry && onPerfEntry instanceof Function) {
import('web-vitals').then(({ getCLS, getFID, getFCP, getLCP, getTTFB }) => { import('web-vitals').then(({ onCLS, onINP, onFCP, onLCP, onTTFB }) => {
getCLS(onPerfEntry); onCLS(onPerfEntry);
getFID(onPerfEntry); onINP(onPerfEntry);
getFCP(onPerfEntry); onFCP(onPerfEntry);
getLCP(onPerfEntry); onLCP(onPerfEntry);
getTTFB(onPerfEntry); onTTFB(onPerfEntry);
}); });
} }
}; };
+7 -4
View File
@@ -5,17 +5,20 @@
"types": ["vite/client"], "types": ["vite/client"],
"allowJs": false, "allowJs": false,
"skipLibCheck": true, "skipLibCheck": true,
"esModuleInterop": false, "esModuleInterop": true,
"allowSyntheticDefaultImports": true, "allowSyntheticDefaultImports": true,
"strict": true, "strict": true,
"forceConsistentCasingInFileNames": true, "forceConsistentCasingInFileNames": true,
"noFallthroughCasesInSwitch": true, "noFallthroughCasesInSwitch": true,
"module": "esnext", "module": "ESNext",
"moduleResolution": "node", "moduleResolution": "Bundler",
"resolveJsonModule": true, "resolveJsonModule": true,
"isolatedModules": true, "isolatedModules": true,
"noEmit": true, "noEmit": true,
"jsx": "react-jsx" "jsx": "react-jsx",
"paths": {
"@/*": ["./src/*"]
}
}, },
"include": [ "include": [
"src" "src"