Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,23 @@ export default defineConfig([
languageOptions: {
globals: globals.browser,
},
rules: {
// The classic correctness rule (rules-of-hooks) and exhaustive-deps stay
// on. The two overrides below dial back React-Compiler-era hints that flag
// pre-existing, intentional patterns in this codebase:
//
// - `refs`: we assign `ref.current = value` during render to keep a
// "latest value" ref for stable sync callbacks. Deferring it into an
// effect would make the ref lag a render and risk stale reads, so this
// pattern is deliberate — disable the rule rather than regress it.
'react-hooks/refs': 'off',
// - `set-state-in-effect`: the flagged effects reset/lazy-load state when
// a dependency changes (clear error on note switch, load backups on tab
// open, reset media URL on id change). These are legitimate; keep them
// visible as warnings to revisit during the planned component refactor,
// but don't block CI.
'react-hooks/set-state-in-effect': 'warn',
},
},

// Sync server — Node TypeScript, no browser/React rules.
Expand Down
Loading