Files
invbrain.neuroinf.jp/package.json
T
orrisroot 79e0e2295f feat: migrate from Create React App to Vite
react-scripts 4 on React 17 no longer builds on a current toolchain.
Move to Vite 8 with React 19 and TypeScript 7, and take the same shape
as the other converted sites.

- react-router-dom v5 -> react-router v8: Switch/Redirect become
  Routes/Navigate, and withRouter gives way to useLocation and
  useNavigate; the original /modules/... addresses are kept
- swap the unmaintained dependencies: axios -> ky, react-html-parser
  -> @orrisroot/react-html-parser, react-ga -> react-ga4,
  react-helmet -> @dr.pogodin/react-helmet, moment -> date-fns,
  react-spinner-material -> a CSS spinner, and a local HashLink in
  place of react-router-hash-link
- drop react-app-polyfill, the jest setup, xregexp and the unused
  async-lock, rc-tree, react-overlays and react-image-lightbox
- replace ESLint with Biome, yarn with npm, and match the other sites'
  tsconfigs and sanitize.css base stylesheet
- serve static-contents/ next to the repository with sirv in the dev
  and preview servers, keeping it out of dist/
- convert the page components to function components; each module
  loads its index once, sharing the request under StrictMode
- resolve relative links in page bodies the way a browser does, since
  react-router 8 resolves them against the route hierarchy
- fix the glossary search restricted to a category, whose query
  matched nothing
- set the GA4 measurement ID replacing the shut-down UA property
- correct the keywords meta tag copied from dynamicbrain
- write down the data layout and the deployment procedure
2026-09-15 12:56:11 +09:00

39 lines
1.0 KiB
JSON

{
"name": "invbrain",
"version": "2.0.0",
"private": true,
"type": "module",
"scripts": {
"dev": "vite",
"build": "tsc -b && vite build",
"preview": "vite preview",
"lint": "biome lint",
"format": "biome format --write",
"check": "biome check --write"
},
"dependencies": {
"@dr.pogodin/react-helmet": "^3.2.3",
"@orrisroot/react-html-parser": "^3.0.1",
"date-fns": "^4.4.0",
"ky": "^2.1.0",
"lokijs": "^1.5.12",
"react": "^19.3.0",
"react-cookie": "^8.1.2",
"react-dom": "^19.3.0",
"react-ga4": "^3.0.1",
"react-router": "^8.3.1",
"sanitize.css": "^13.0.0"
},
"devDependencies": {
"@biomejs/biome": "^2.5.13",
"@types/lokijs": "^1.5.14",
"@types/node": "^24.13.4",
"@types/react": "^19.3.0",
"@types/react-dom": "^19.3.0",
"@vitejs/plugin-react": "^6.1.1",
"sirv": "^3.0.2",
"typescript": "~7.0.2",
"vite": "^8.3.0"
}
}