Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ESLintの設定を @antfu/eslint-config を使った形に変更する #347

Closed
1 task
keitakn opened this issue Sep 9, 2024 · 0 comments
Closed
1 task
Assignees

Comments

@keitakn
Copy link
Member

keitakn commented Sep 9, 2024

完了の定義

補足情報

以下のように設定すれば良さそう。

import antfu from '@antfu/eslint-config'
import tailwindcss from 'eslint-plugin-tailwindcss'

export default antfu(
  {
    react: true,
    ignores: [],
  },
  ...tailwindcss.configs['flat/recommended'],
)

依存packageとして以下が必要なようだ。

https://github.com/antfu/eslint-config

npm i -D @eslint-react/eslint-plugin eslint-plugin-react-hooks eslint-plugin-react-refresh
@keitakn keitakn self-assigned this Sep 9, 2024
keitakn added a commit that referenced this issue Oct 9, 2024
keitakn added a commit that referenced this issue Oct 10, 2024
src/utils/gtm.ts
  36:13  error  Use a `type` instead of an `interface`                                             ts/consistent-type-definitions
  42:3   error  Definition for rule '@typescript-eslint/strict-boolean-expressions' was not found  @typescript-eslint/strict-boolean-expressions
  51:3   error  Definition for rule '@typescript-eslint/strict-boolean-expressions' was not found  @typescript-eslint/strict-boolean-expressions
  60:3   error  Definition for rule '@typescript-eslint/strict-boolean-expressions' was not found  @typescript-eslint/strict-boolean-expressions
  69:3   error  Definition for rule '@typescript-eslint/strict-boolean-expressions' was not found  @typescript-eslint/strict-boolean-expressions
  78:3   error  Definition for rule '@typescript-eslint/strict-boolean-expressions' was not found  @typescript-eslint/strict-boolean-expressions
  87:3   error  Definition for rule '@typescript-eslint/strict-boolean-expressions' was not found  @typescript-eslint/strict-boolean-expressions
  96:3   error  Definition for rule '@typescript-eslint/strict-boolean-expressions' was not found  @typescript-eslint/strict-boolean-expressions
keitakn added a commit that referenced this issue Oct 10, 2024
src/utils/assertNever.ts
  1:1   error  Definition for rule '@typescript-eslint/no-unused-vars' was not found    @typescript-eslint/no-unused-vars
  2:29  error  'value' is defined but never used. Allowed unused args must match /^_/u  unused-imports/no-unused-vars
keitakn added a commit that referenced this issue Oct 10, 2024
/lgtm-cat-frontend/src/app/_components/Header.test.tsx
  31:51  warning  Use shorthand boolean attribute 'isLoggedIn'  react/prefer-shorthand-boolean
  42:51  warning  Use shorthand boolean attribute 'isLoggedIn'  react/prefer-shorthand-boolean

/lgtm-cat-frontend/src/app/_components/HeaderLogo.tsx
  21:41  warning  Use shorthand boolean attribute 'aria-hidden'  react/prefer-shorthand-boolean

/lgtm-cat-frontend/src/app/_components/LoginButton.tsx
  14:7  warning  Use shorthand boolean attribute 'showGithubIcon'  react/prefer-shorthand-boolean
@keitakn keitakn closed this as completed Oct 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant