From 354990ac631ba0f9e2fa7f1929a998d772df101b Mon Sep 17 00:00:00 2001 From: Nikhil Bhatia Date: Wed, 5 Aug 2026 23:48:25 +0000 Subject: [PATCH 1/7] Client: Upgrade TypeScript to 6.0/7.0 dual-compiler setup Install typescript 7.0.2 (native compiler) for the tsc binary and @typescript/typescript6 6.0.2 as the typescript package for tools that consume the JS API (typescript-eslint, tsserver, Cypress). - moduleResolution "node" was removed in TS 7; switch to "bundler" - resolvePackageJsonExports: false defers a react-hook-form v7 upgrade (v6's exports map hides its type declarations from bundler resolution) - vite-env.d.ts satisfies TS 7's new check that side-effect CSS imports resolve (TS2882) Co-Authored-By: Claude Fable 5 --- client/package.json | 3 +- client/src/vite-env.d.ts | 1 + client/tsconfig.json | 23 ++----- client/yarn.lock | 141 +++++++++++++++++++++++++++++++++++++-- 4 files changed, 146 insertions(+), 22 deletions(-) create mode 100644 client/src/vite-env.d.ts diff --git a/client/package.json b/client/package.json index 5ebe23383..104aca412 100644 --- a/client/package.json +++ b/client/package.json @@ -118,6 +118,7 @@ "@types/yup": "^0.26.22", "@typescript-eslint/eslint-plugin": "^3.0.1", "@typescript-eslint/parser": "^3.0.1", + "@typescript/native": "npm:typescript@7.0.2", "@vitest/coverage-v8": "^4.0.4", "babel-preset-react-app": "^9.1.1", "camelcase": "^5.3.1", @@ -148,7 +149,7 @@ "stylelint-config-prettier": "^5.1.0", "stylelint-config-styled-components": "^0.1.1", "stylelint-processor-styled-components": "^1.10.0", - "typescript": "^5.9.2", + "typescript": "npm:@typescript/typescript6@6.0.2", "vitest": "^4.0.4", "vitest-canvas-mock": "^0.3.3" } diff --git a/client/src/vite-env.d.ts b/client/src/vite-env.d.ts new file mode 100644 index 000000000..11f02fe2a --- /dev/null +++ b/client/src/vite-env.d.ts @@ -0,0 +1 @@ +/// diff --git a/client/tsconfig.json b/client/tsconfig.json index 28d2ddf42..fc6a1ff39 100644 --- a/client/tsconfig.json +++ b/client/tsconfig.json @@ -1,11 +1,7 @@ { "compilerOptions": { "target": "es2015", - "lib": [ - "dom", - "dom.iterable", - "esnext" - ], + "lib": ["dom", "dom.iterable", "esnext"], "allowJs": true, "skipLibCheck": true, "esModuleInterop": true, @@ -13,24 +9,17 @@ "strict": true, "forceConsistentCasingInFileNames": true, "module": "esnext", - "moduleResolution": "node", + "moduleResolution": "bundler", + "resolvePackageJsonExports": false, "resolveJsonModule": true, "isolatedModules": true, "incremental": true, "declaration": true, "emitDeclarationOnly": true, "outDir": "dist", - "types": [ - "node", - "@testing-library/jest-dom" - ], + "types": ["node", "@testing-library/jest-dom"], "jsx": "preserve" }, - "include": [ - "src", - ], - "exclude": [ - "**/node_modules", - "**/.*/" - ] + "include": ["src"], + "exclude": ["**/node_modules", "**/.*/"] } diff --git a/client/yarn.lock b/client/yarn.lock index c246d81da..8d58e8606 100644 --- a/client/yarn.lock +++ b/client/yarn.lock @@ -2331,6 +2331,137 @@ dependencies: eslint-visitor-keys "^1.1.0" +"@typescript/native@npm:typescript@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-7.0.2.tgz#9ec773d7954a8c182c17cc5bbd575aa28bc51582" + integrity sha512-8FYau96o3NKOhbjKi/qNvG/W5jhzxkbdm5sj9AbZ/5T5sWqn3hJgLfGx27sRKZWTvyzCP8dLRBTf5tBTSRVUNA== + optionalDependencies: + "@typescript/typescript-aix-ppc64" "7.0.2" + "@typescript/typescript-darwin-arm64" "7.0.2" + "@typescript/typescript-darwin-x64" "7.0.2" + "@typescript/typescript-freebsd-arm64" "7.0.2" + "@typescript/typescript-freebsd-x64" "7.0.2" + "@typescript/typescript-linux-arm" "7.0.2" + "@typescript/typescript-linux-arm64" "7.0.2" + "@typescript/typescript-linux-loong64" "7.0.2" + "@typescript/typescript-linux-mips64el" "7.0.2" + "@typescript/typescript-linux-ppc64" "7.0.2" + "@typescript/typescript-linux-riscv64" "7.0.2" + "@typescript/typescript-linux-s390x" "7.0.2" + "@typescript/typescript-linux-x64" "7.0.2" + "@typescript/typescript-netbsd-arm64" "7.0.2" + "@typescript/typescript-netbsd-x64" "7.0.2" + "@typescript/typescript-openbsd-arm64" "7.0.2" + "@typescript/typescript-openbsd-x64" "7.0.2" + "@typescript/typescript-sunos-x64" "7.0.2" + "@typescript/typescript-win32-arm64" "7.0.2" + "@typescript/typescript-win32-x64" "7.0.2" + +"@typescript/old@npm:typescript@^6": + version "6.0.3" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-6.0.3.tgz#90251dc007916e972786cb94d74d15b185577d21" + integrity sha512-y2TvuxSZPDyQakkFRPZHKFm+KKVqIisdg9/CZwm9ftvKXLP8NRWj38/ODjNbr43SsoXqNuAisEf1GdCxqWcdBw== + +"@typescript/typescript-aix-ppc64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-aix-ppc64/-/typescript-aix-ppc64-7.0.2.tgz#cdc7ce81d60f1e09034960ddfb1fb880d7a776b6" + integrity sha512-MTKKkWB7p/0E9xi1d1tHtZ5PiLkGEMIq88pK2CubZjOsLtYTLqhgIgi6zepFa+9GHZ6h05NMCkQxGKiPXMxXtQ== + +"@typescript/typescript-darwin-arm64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-darwin-arm64/-/typescript-darwin-arm64-7.0.2.tgz#a55fdfcfa58df58d27db2237cde6a5c1e35a7235" + integrity sha512-gowzar9MwS/aRWp6f3a4KUqzRjAZjOsmGNCM6LcTgXum+dBfgsBVMN+AgvOCCbguXyick6LJhpBszxMebJ8syA== + +"@typescript/typescript-darwin-x64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-darwin-x64/-/typescript-darwin-x64-7.0.2.tgz#38d1c9172800a91d707bec64d2a370a016634db4" + integrity sha512-SZ9xZInqApNlNGc9s0W1VSsktYSOe9cFqNOIqmN1Gs8SmkjKZYFt017G4VwPxASInODuAdbTW7sXiFUf893RgA== + +"@typescript/typescript-freebsd-arm64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-freebsd-arm64/-/typescript-freebsd-arm64-7.0.2.tgz#f1ff8810030b35d2b5be0db6a2dc650460ea94fa" + integrity sha512-W5NH4y/J0plIIS5b2xvTEkU7JFxyqdMAOgf+Ilhl0vHQXKO5dZoxd+C/jEtq56c4F3wk71RB4BMRQ2XdI+bwYQ== + +"@typescript/typescript-freebsd-x64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-freebsd-x64/-/typescript-freebsd-x64-7.0.2.tgz#3d86b03f353c5b1ba95162eb6ce35533bfc294bd" + integrity sha512-UMGDx5sTpzNw3WiPebH7l90IWfJggEd+egHt/q6p7/Cm3zqoV7VxkGXt+3DxPIw8CcmvAB0j3sVVfbhX+M4Tpw== + +"@typescript/typescript-linux-arm64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-linux-arm64/-/typescript-linux-arm64-7.0.2.tgz#d9334d96d6dac6ff85da9c865588948de939e91f" + integrity sha512-Qh4eU4/y3yDjnfjjyPYihMj5/ODIlmt+Bzu17OI+fiSRDW57QmU5SiN63exPRNJPKUzcc1INa1NXdrJ+MqHjUQ== + +"@typescript/typescript-linux-arm@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-linux-arm/-/typescript-linux-arm-7.0.2.tgz#ad94b41e1aee2a4dcc6a298c7b67c43345fde32e" + integrity sha512-gffT3xPz9sR7j/YJExkyPntrI0P2EP9XbOyWzth2/Gs0RstK+90RBcO0ncXoXy/beYll1SXw846Nf2zdnEz0QQ== + +"@typescript/typescript-linux-loong64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-linux-loong64/-/typescript-linux-loong64-7.0.2.tgz#2965aee4fc873360139d893daafe6397a29138ad" + integrity sha512-uEHck9i8hoAzXPiYRib1O7miOnz23SxIeVl6F4LXox+qov1K35jHcEW6VHKvZI+pyvl7fZEP4MCU5LYvIq1GuQ== + +"@typescript/typescript-linux-mips64el@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-linux-mips64el/-/typescript-linux-mips64el-7.0.2.tgz#1a887a311bed3a833f80bfd4a9ed37c271936cf0" + integrity sha512-R4KvAMnE43W5Qeqb0Ly56O3mWMWIAgsMyz36DCaycd5nbg/9kzm0liw3JocfRqyJY0KPmzFjbswozXyW0DnIYA== + +"@typescript/typescript-linux-ppc64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-linux-ppc64/-/typescript-linux-ppc64-7.0.2.tgz#8b63c9b2f445b393eb4e43ec21da225dade3577d" + integrity sha512-DORx5b3sd/4S7eayxm4FQv+A7CrkUIGRaHiwI8oiHTAI1fAPWhF4J0vAlkC8biAlHSVVwxMQ3tjZ2/DVbnQiiA== + +"@typescript/typescript-linux-riscv64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-linux-riscv64/-/typescript-linux-riscv64-7.0.2.tgz#b6e8a35c289b3ea97a92a41d461aaeed0d3b36e1" + integrity sha512-wf0jqEDOjrPRnKwYRyyJDRo11KMbvMFrU+q4zqKyChODBzvlkbhNQfKvLxQCcwTpdDaXSHZTVuh0JoCrKCUMHQ== + +"@typescript/typescript-linux-s390x@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-linux-s390x/-/typescript-linux-s390x-7.0.2.tgz#2ef96693be4861f6d17965427e5b009cbbed1a3e" + integrity sha512-IkwJc3L7yhytWd/ewjyxNDfOmswCm9GWMJT/ue/dU4aZNbwZeYAetq42VyLmsmSjvoX7z74X6ZaYCtzAr0EuGw== + +"@typescript/typescript-linux-x64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-linux-x64/-/typescript-linux-x64-7.0.2.tgz#73269cb0baba50aea0ca060445a6b88e583f1ce2" + integrity sha512-EYdf2cNg7rgCWJnxCdJ+F3V39O8ihb37eHAu1LK8oAFizgTQbPOK7zHHXbPt8rX24COqODXeI3sIf0fCXG7H/A== + +"@typescript/typescript-netbsd-arm64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-netbsd-arm64/-/typescript-netbsd-arm64-7.0.2.tgz#3a3649f97fafa210b4e6e3798c15e06605c8a901" + integrity sha512-+polYF4MF04aPpO5FTkHran9yUQDSXqy5GiSDKpsll5jy3l3+g9QLhpf39T+ePtefhXLOGrLl0QIjkQP6VnelA== + +"@typescript/typescript-netbsd-x64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-netbsd-x64/-/typescript-netbsd-x64-7.0.2.tgz#47ec59491a40c470d2807dc4d2b825528fd979ab" + integrity sha512-8YIT0EHM/3dq10ZOVF/A7pc/YSMtbcecct4rWtexrnSCHOPcpC2KTLXfTCR6vDpnSiY12heNb1GiN/wu+T/FyA== + +"@typescript/typescript-openbsd-arm64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-openbsd-arm64/-/typescript-openbsd-arm64-7.0.2.tgz#796be8da0bd989d8a3fb96f2801e38a8365b4baf" + integrity sha512-APT8+ClYnuYm1u9+kgGXoMj2VzWzcymwh2gNSQVySHfkRDGOTVkoWLjCmOQSaO+PoqQ57B0flRp9SA+7GnnkzQ== + +"@typescript/typescript-openbsd-x64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-openbsd-x64/-/typescript-openbsd-x64-7.0.2.tgz#d37fe2a729eb942c076c454ee7f1815faf7d560f" + integrity sha512-yX7s+Q0Dln0Dt9tEzZsAjXXR/+ytBM7AlglaqyeMPxQszJ1JhlJdZ6jLA+IzldHtflX81em7lDao1xXu+aRRkg== + +"@typescript/typescript-sunos-x64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-sunos-x64/-/typescript-sunos-x64-7.0.2.tgz#aba8d3464c3565a7044789baba96916bd4ab2c88" + integrity sha512-dLJDGaLZ1D4HPQn62u1n8mBDkJREwMsAkCdkwd4Ieqw+x3TUyTsqY0YiBCtE6H6OzzgGk3iuZ3vFWRS+E8/d1g== + +"@typescript/typescript-win32-arm64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-win32-arm64/-/typescript-win32-arm64-7.0.2.tgz#b9de50a17196383f62620b5f9d0a2f34ad3b60d7" + integrity sha512-Gyl1Vy6OsWesLzmq+EP0Fb7b4Nid5232AvcA2SFcdYreldpNtYFFofPjnt62y9hQy7VTaZp65ICJjuAQRaVcIQ== + +"@typescript/typescript-win32-x64@7.0.2": + version "7.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript-win32-x64/-/typescript-win32-x64-7.0.2.tgz#cf3b7b0d6ce5635daca4c8e01c189cdcde47ec3c" + integrity sha512-0BQ3HkAHHlKLSp1qRvf3SUhGpGsDuhB/jgFw75guyqbxJqEaS0Cw/VFO8i2nHglJUzQCRtMMR/IBAKE3ETMC4g== + "@vitejs/plugin-react@^5.0.4": version "5.0.4" resolved "https://registry.yarnpkg.com/@vitejs/plugin-react/-/plugin-react-5.0.4.tgz#d642058e89c5b712655c8cbd13482f5813519602" @@ -10360,10 +10491,12 @@ typed-styles@^0.0.7: resolved "https://registry.yarnpkg.com/typed-styles/-/typed-styles-0.0.7.tgz#93392a008794c4595119ff62dde6809dbc40a3d9" integrity sha512-pzP0PWoZUhsECYjABgCGQlRGL1n7tOHsgwYv3oIiEpJwGhFTuty/YNeduxQYzXXa3Ge5BdT6sHYIQYpl4uJ+5Q== -typescript@^5.9.2: - version "5.9.2" - resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.9.2.tgz#d93450cddec5154a2d5cabe3b8102b83316fb2a6" - integrity sha512-CWBzXQrc/qOkhidw1OzBTQuYRbfyxDXJMVJ1XNwUHGROVmuaeiEm3OslpZ1RV96d7SKKjZKrSJu3+t/xlw3R9A== +"typescript@npm:@typescript/typescript6@6.0.2": + version "6.0.2" + resolved "https://registry.yarnpkg.com/@typescript/typescript6/-/typescript6-6.0.2.tgz#79e0e47492564c83f8602013d7dd10d5ebc51a8c" + integrity sha512-mbCddXd+jm7hfx7w2YU64/Av4/NqqeG3GoRZgxPcgoTxYjhrcfJRw9ULch71SS4G+Q3bOXFhRvPqjguN0Hyp5w== + dependencies: + "@typescript/old" "npm:typescript@^6" unbox-primitive@^1.0.2: version "1.0.2" From e40be14274cf0b5e4be869a9b411dd8d196263ca Mon Sep 17 00:00:00 2001 From: Nikhil Bhatia Date: Mon, 17 Aug 2026 18:01:15 +0000 Subject: [PATCH 2/7] Client: Switch tsc to noEmit type-checking MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The declaration/emitDeclarationOnly/outDir setup wrote a dist/ tree of .d.ts files on every tsc run (CI and pre-commit) that nothing consumes: the app is bundled by Vite into build/, and no tooling reads client/dist. noEmit expresses the actual intent — tsc is a type-check gate only. rootDir must still be set explicitly (with a comment saying why): Cypress loads cypress.config.ts through ts-node, which forces an internal outDir, and TS 6 fails there with error TS5011 when rootDir is left inferred. This is also what broke the Cypress CI job after the TS 6/7 upgrade. Co-Authored-By: Claude Fable 5 --- client/tsconfig.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/client/tsconfig.json b/client/tsconfig.json index fc6a1ff39..eb730f77b 100644 --- a/client/tsconfig.json +++ b/client/tsconfig.json @@ -14,9 +14,9 @@ "resolveJsonModule": true, "isolatedModules": true, "incremental": true, - "declaration": true, - "emitDeclarationOnly": true, - "outDir": "dist", + "noEmit": true, + // Cypress loads cypress.config.ts via ts-node, which requires rootDir + "rootDir": ".", "types": ["node", "@testing-library/jest-dom"], "jsx": "preserve" }, From 2d51e74ba2dd00529dc6e5dd44ba279295d9dcbd Mon Sep 17 00:00:00 2001 From: Nikhil Bhatia Date: Mon, 17 Aug 2026 21:55:23 +0000 Subject: [PATCH 3/7] Client: Fix VS Code workspace TypeScript SDK path The typescript package is now the @typescript/typescript6 wrapper, which ships no lib/tsserver.js, so VS Code silently fell back to its bundled TypeScript. Point tsdk at @typescript/old (the real TS 6 compiler the wrapper re-exports), which does ship tsserver.js. Co-Authored-By: Claude Fable 5 --- arlo.code-workspace | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arlo.code-workspace b/arlo.code-workspace index aed87c78e..eff3b36da 100644 --- a/arlo.code-workspace +++ b/arlo.code-workspace @@ -15,7 +15,7 @@ "remotePort": 3000 } ], - "typescript.tsdk": "client/node_modules/typescript/lib", + "typescript.tsdk": "client/node_modules/@typescript/old/lib", "editor.defaultFormatter": "esbenp.prettier-vscode", "editor.formatOnSave": true, "[python]": { From baf328e349e5fe168e7df0ffc21facf6ad0b7ec5 Mon Sep 17 00:00:00 2001 From: Nikhil Bhatia Date: Mon, 17 Aug 2026 22:46:46 +0000 Subject: [PATCH 4/7] Client: Mark Makefile targets .PHONY make build silently no-ops when Vite's build/ output directory exists, because make treats the directory as the target being up to date. Co-Authored-By: Claude Fable 5 --- client/Makefile | 2 ++ 1 file changed, 2 insertions(+) diff --git a/client/Makefile b/client/Makefile index c1b2279f2..a2c4988dd 100644 --- a/client/Makefile +++ b/client/Makefile @@ -1,3 +1,5 @@ +.PHONY: install lint test build + install: yarn install From 299e98a8798dfb12c6a27d8203c7026cc465635e Mon Sep 17 00:00:00 2001 From: Nikhil Bhatia Date: Mon, 17 Aug 2026 22:47:17 +0000 Subject: [PATCH 5/7] CI: Lint and production-build the client MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Client lint previously ran only in the pre-commit hook (skippable, and absent for bot commits), and vite build ran for the first time at deploy — a change could pass CI and still fail the Heroku build. build-and-test-client now runs both, using the existing client Makefile targets. Co-Authored-By: Claude Fable 5 --- .circleci/config.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 85a0cb38e..9a584ee9d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -98,10 +98,18 @@ jobs: command: | sudo apt-get update sudo apt-get install graphicsmagick + - run: + name: lint client + command: | + make -C client lint - run: name: test client command: | make -C client test + - run: + name: build client + command: | + make -C client build - store_test_results: path: client/test_results From 6fc8048b626e9a5622cc9c2e271a68c936c545d9 Mon Sep 17 00:00:00 2001 From: Nikhil Bhatia Date: Mon, 17 Aug 2026 22:54:39 +0000 Subject: [PATCH 6/7] Client: Delete CRA-era react-app-env.d.ts vite/client (referenced by vite-env.d.ts) already declares every asset module the CRA shim declared. The shim's *.svg ReactComponent export was a trap: the CRA idiom type-checked but is undefined at runtime under Vite (no svgr plugin). Its NODE_ENV literal-union narrowing is the one piece worth keeping, so it moves to vite-env.d.ts. Co-Authored-By: Claude Fable 5 --- client/src/react-app-env.d.ts | 66 ----------------------------------- client/src/vite-env.d.ts | 7 ++++ 2 files changed, 7 insertions(+), 66 deletions(-) delete mode 100644 client/src/react-app-env.d.ts diff --git a/client/src/react-app-env.d.ts b/client/src/react-app-env.d.ts deleted file mode 100644 index 981cd7347..000000000 --- a/client/src/react-app-env.d.ts +++ /dev/null @@ -1,66 +0,0 @@ -/// -/// -/// - -declare namespace NodeJS { - interface ProcessEnv { - readonly NODE_ENV: 'development' | 'production' | 'test'; - readonly PUBLIC_URL: string; - } -} - -declare module '*.bmp' { - const src: string; - export default src; -} - -declare module '*.gif' { - const src: string; - export default src; -} - -declare module '*.jpg' { - const src: string; - export default src; -} - -declare module '*.jpeg' { - const src: string; - export default src; -} - -declare module '*.png' { - const src: string; - export default src; -} - -declare module '*.webp' { - const src: string; - export default src; -} - -declare module '*.svg' { - import * as React from 'react'; - - export const ReactComponent: React.FunctionComponent & { title?: string }>; - - const src: string; - export default src; -} - -declare module '*.module.css' { - const classes: { readonly [key: string]: string }; - export default classes; -} - -declare module '*.module.scss' { - const classes: { readonly [key: string]: string }; - export default classes; -} - -declare module '*.module.sass' { - const classes: { readonly [key: string]: string }; - export default classes; -} diff --git a/client/src/vite-env.d.ts b/client/src/vite-env.d.ts index 11f02fe2a..880c1d28d 100644 --- a/client/src/vite-env.d.ts +++ b/client/src/vite-env.d.ts @@ -1 +1,8 @@ /// + +// Vite statically replaces process.env.NODE_ENV at build time. +declare namespace NodeJS { + interface ProcessEnv { + readonly NODE_ENV: 'development' | 'production' | 'test' + } +} From 059247ca7f87a26ced6ec8f5befb22c8da4e1885 Mon Sep 17 00:00:00 2001 From: Nikhil Bhatia Date: Mon, 17 Aug 2026 23:17:47 +0000 Subject: [PATCH 7/7] Client: Drop dead @types/jspdf and @types/react-toastify MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit jspdf 4 and react-toastify 5 ship their own type declarations, which TypeScript prefers over @types packages, so these v1-era and v4-era stubs were never consulted — only available to drift from the real APIs. Co-Authored-By: Claude Fable 5 --- client/package.json | 2 -- client/yarn.lock | 20 -------------------- 2 files changed, 22 deletions(-) diff --git a/client/package.json b/client/package.json index 104aca412..3e1a4ca1a 100644 --- a/client/package.json +++ b/client/package.json @@ -103,14 +103,12 @@ "@testing-library/react-hooks": "^3.3.0", "@testing-library/user-event": "^12.3.0", "@types/d3": "^6.7.0", - "@types/jspdf": "^1.3.3", "@types/node": "12.0.7", "@types/qrcode.react": "^0.8.2", "@types/react": "16.9.0", "@types/react-dom": "16.9.8", "@types/react-router-dom": "^5.1.3", "@types/react-table": "^7.7.1", - "@types/react-toastify": "^4.0.2", "@types/styled-components": "^5.1.2", "@types/topojson-client": "^3.1.0", "@types/topojson-specification": "^1.0.1", diff --git a/client/yarn.lock b/client/yarn.lock index 8d58e8606..5305a208b 100644 --- a/client/yarn.lock +++ b/client/yarn.lock @@ -1997,11 +1997,6 @@ resolved "https://registry.yarnpkg.com/@types/json5/-/json5-0.0.29.tgz#ee28707ae94e11d2b827bcbe5270bcea7f3e71ee" integrity sha512-dRLjCWHYg4oaA77cxO64oO+7JwCwnIzkZPdrrC71jQmQtlhM556pwKo5bUzqvZndkVbeFLIIi+9TC40JNF5hNQ== -"@types/jspdf@^1.3.3": - version "1.3.3" - resolved "https://registry.yarnpkg.com/@types/jspdf/-/jspdf-1.3.3.tgz#6940e892da69fdbe0969b742c6bdd9e4c5da320b" - integrity sha512-DqwyAKpVuv+7DniCp2Deq1xGvfdnKSNgl9Agun2w6dFvR5UKamiv4VfYUgcypd8S9ojUyARFIlZqBrYrBMQlew== - "@types/minimatch@*": version "3.0.3" resolved "https://registry.yarnpkg.com/@types/minimatch/-/minimatch-3.0.3.tgz#3dca0e3f33b200fc7d1139c0cd96c1268cadfd9d" @@ -2109,21 +2104,6 @@ dependencies: "@types/react" "*" -"@types/react-toastify@^4.0.2": - version "4.0.2" - resolved "https://registry.yarnpkg.com/@types/react-toastify/-/react-toastify-4.0.2.tgz#a7db2002c0b3080b28969e9d6a8d4daeb18baa6d" - integrity sha512-pHjCstnN0ZgopIWQ9UiWsD9n+HsXs1PnMQC4hIZuSzpDO0lRjigpTuqsUtnBkMbLIg+mGFSAsBjL49SspzoLKA== - dependencies: - "@types/react" "*" - "@types/react-transition-group" "*" - -"@types/react-transition-group@*": - version "4.2.0" - resolved "https://registry.yarnpkg.com/@types/react-transition-group/-/react-transition-group-4.2.0.tgz#86ddb509ce3de27341c7cb7797abb99b1c4676bf" - integrity sha512-8KkpFRwqS9U1dtVVw1kt/MmWgLmbd5iK5TgqsaeC7fAm74J4j/HiBiRC8eETvwjGGju48RAwyZ3l5iv1H1x93Q== - dependencies: - "@types/react" "*" - "@types/react@*": version "16.9.23" resolved "https://registry.yarnpkg.com/@types/react/-/react-16.9.23.tgz#1a66c6d468ba11a8943ad958a8cb3e737568271c"