forked from cardosofelipe/fast-next-template
- Extracted password reset logic into `PasswordResetConfirmContent` wrapped in `Suspense` for cleaner and more modular component structure. - Updated ESLint config to ignore generated files and added rules for stricter code quality (`eslint-comments`, `@typescript-eslint` adjustments). - Automated insertion of `eslint-disable` in auto-generated TypeScript files through `generate-api-client.sh`. - Replaced unsafe `any` type casts with safer `Record<string, unknown>` type assertions for TypeScript compliance. - Added `lint:tests` script for pre-commit test coverage checks. - Improved `useAuth` hooks and related type guards for better runtime safety and maintainability.
30 lines
637 B
JavaScript
Executable File
30 lines
637 B
JavaScript
Executable File
import { dirname } from "path";
|
|
import { fileURLToPath } from "url";
|
|
import { FlatCompat } from "@eslint/eslintrc";
|
|
|
|
const __filename = fileURLToPath(import.meta.url);
|
|
const __dirname = dirname(__filename);
|
|
|
|
const compat = new FlatCompat({
|
|
baseDirectory: __dirname,
|
|
});
|
|
|
|
const eslintConfig = [
|
|
...compat.extends("next/core-web-vitals", "next/typescript"),
|
|
{
|
|
ignores: [
|
|
"**/node_modules/**",
|
|
"**/.next/**",
|
|
"**/out/**",
|
|
"**/build/**",
|
|
"**/dist/**",
|
|
"**/coverage/**",
|
|
"**/src/lib/api/generated/**",
|
|
"**/*.gen.ts",
|
|
"**/*.gen.tsx",
|
|
],
|
|
},
|
|
];
|
|
|
|
export default eslintConfig;
|