Setup initial project
This commit is contained in:
commit
db79af06f7
119 changed files with 20761 additions and 0 deletions
47
packages/web/eslint.config.js
Normal file
47
packages/web/eslint.config.js
Normal file
|
|
@ -0,0 +1,47 @@
|
|||
import tseslint from 'typescript-eslint';
|
||||
import reactPlugin from 'eslint-plugin-react';
|
||||
import reactHooksPlugin from 'eslint-plugin-react-hooks';
|
||||
import nextPlugin from '@next/eslint-plugin-next';
|
||||
import prettierRecommended from 'eslint-plugin-prettier/recommended';
|
||||
|
||||
export default tseslint.config(
|
||||
{ ignores: ['.next/**', 'coverage/**'] },
|
||||
...tseslint.configs.recommended,
|
||||
// React flat config — uses JSX runtime transform (no need to import React)
|
||||
reactPlugin.configs.flat['jsx-runtime'],
|
||||
// React Hooks
|
||||
{
|
||||
plugins: { 'react-hooks': reactHooksPlugin },
|
||||
rules: reactHooksPlugin.configs.recommended.rules,
|
||||
},
|
||||
// Next.js
|
||||
{
|
||||
plugins: { '@next/next': nextPlugin },
|
||||
rules: {
|
||||
...nextPlugin.configs.recommended.rules,
|
||||
...nextPlugin.configs['core-web-vitals'].rules,
|
||||
},
|
||||
},
|
||||
{
|
||||
settings: {
|
||||
react: { version: 'detect' },
|
||||
},
|
||||
rules: {
|
||||
'@typescript-eslint/no-explicit-any': 'error',
|
||||
'@typescript-eslint/explicit-member-accessibility': ['error', { accessibility: 'explicit' }],
|
||||
'@typescript-eslint/no-unused-vars': [
|
||||
'error',
|
||||
{
|
||||
argsIgnorePattern: '^_',
|
||||
varsIgnorePattern: '^_',
|
||||
caughtErrorsIgnorePattern: '^_',
|
||||
},
|
||||
],
|
||||
'@typescript-eslint/consistent-type-imports': [
|
||||
'error',
|
||||
{ prefer: 'type-imports', fixStyle: 'inline-type-imports' },
|
||||
],
|
||||
},
|
||||
},
|
||||
prettierRecommended,
|
||||
);
|
||||
Loading…
Add table
Add a link
Reference in a new issue