Files
copilotkit__copilotkit/examples/showcases/banking/eslint.config.mjs
GeneralJerel 3b06802423 fix(showcase): migrate banking demo lint to eslint cli (next 16 removed next lint)
next lint was removed in Next 16, so the demo's lint script failed before
linting anything. Switch to eslint . with a flat eslint.config.mjs built on
eslint-config-next's native flat exports (same shape as the other Next 16
example apps), and fix the findings the new react-hooks rules surfaced:

- actions.ts / team/actions.ts: wrap mount fetches in an async IIFE so
  set-state-in-effect can see the setState calls are asynchronous
- auth-context: derive currentUser from selection ?? team[0] instead of
  syncing state in an effect
- use-theme: lazy-init theme from localStorage (SSR-guarded) and apply the
  DOM class in an effect keyed on theme; hoist applyTheme to module scope
- threads-drawer: copy timeout maps to locals inside the effect so cleanup
  does not read refs that may have changed
2026-06-11 02:29:32 -07:00

21 lines
416 B
JavaScript

import nextCoreWebVitals from "eslint-config-next/core-web-vitals";
import nextTypescript from "eslint-config-next/typescript";
const eslintConfig = [
...nextCoreWebVitals,
...nextTypescript,
{
ignores: [
"node_modules/**",
".next/**",
"out/**",
"build/**",
"next-env.d.ts",
"playwright-report/**",
"test-results/**",
],
},
];
export default eslintConfig;