fix: post-React 19 cleanup — remove dead deps, wire up ESLint plugins, modernize entry#11
Merged
Conversation
…, modernize entry - Remove unused react-router-dom (v7 was never imported anywhere) - Remove redundant autoprefixer (built into Tailwind CSS v4) - Wire up eslint-plugin-react-hooks and eslint-plugin-react-refresh in eslint.config.js (rules-of-hooks, exhaustive-deps now enforced) - Use idiomatic React 19 imports in main.tsx (named createRoot/StrictMode) - Drop `as any` cast on import.meta.env now that vite-env.d.ts provides types - Consolidate duplicate vite-env.d.ts into src/vite-env.d.ts, delete root copy - Re-enable tsc --noEmit and npm audit in CI (both pass clean)
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #11 +/- ##
=======================================
Coverage 71.52% 71.52%
=======================================
Files 6 6
Lines 288 288
=======================================
Hits 206 206
Misses 82 82
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Follow-up cleanup from the React 19 upgrade (PR #10). Addresses overlooked items identified during post-merge review.
Changes
🔴 Fixes
react-router-dom— upgraded to v7 in feat: upgrade to React 19, Vite 8, ESLint 10, TypeScript 6, React Router v7 #10 but never imported anywhere in source code. Eliminates ~7 transitive packages from the dependency tree.eslint-plugin-react-hooks(v7) andeslint-plugin-react-refresh(v0.5) were installed but never configured ineslint.config.js. Now enforcesrules-of-hooks(error) andexhaustive-deps(warn).🟡 Cleanup
main.tsxnow uses named imports (createRoot,StrictMode) instead of namespace import (ReactDOM.createRoot,React.StrictMode).as anycast onimport.meta.env— thevite-env.d.tsadded in feat: upgrade to React 19, Vite 8, ESLint 10, TypeScript 6, React Router v7 #10 provides proper types; the(import.meta as any)workaround inapi.tsis no longer needed.vite-env.d.ts— merged root-levelfrontend/vite-env.d.ts(withImportMetaEnvinterface) intofrontend/src/vite-env.d.ts(the one actually intsconfiginclude path). Deleted the dead root-level copy.autoprefixer— Tailwind CSS v4 includes autoprefixing built-in. Removed from bothpackage.jsonandpostcss.config.js.tsc --noEmitandnpm audit --audit-level=moderatewere skipped with TODO comments; both now pass clean.Verification
npm run lint— passes (now with react-hooks and react-refresh rules active)npx tsc --noEmit— passesnpm run test -- --run— 3/3 passnpm run build— passesnpm audit— 0 vulnerabilitiesnpm outdated— nothing outdated