Skip to content

Commit 2bab04f

Browse files
committed
chore: update ESLint configuration and add @tanstack/eslint-plugin-query
1 parent 83651b7 commit 2bab04f

File tree

3 files changed

+15
-3
lines changed

3 files changed

+15
-3
lines changed

.eslintrc.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const tsconfigPath = require('./tsconfig.json')
1818

1919
module.exports = {
2020
parser: '@typescript-eslint/parser',
21-
plugins: ['@typescript-eslint', 'react', 'prettier', 'import', 'simple-import-sort'],
21+
plugins: ['@typescript-eslint', 'react', 'prettier', 'import', 'simple-import-sort', '@tanstack/query'],
2222
env: {
2323
browser: true,
2424
es2021: true,
@@ -42,6 +42,7 @@ module.exports = {
4242
'airbnb',
4343
'airbnb/hooks',
4444
'prettier',
45+
'plugin:@tanstack/query/recommended',
4546
],
4647
rules: {
4748
'prettier/prettier': ['error'],
@@ -126,9 +127,9 @@ module.exports = {
126127
// Side effect imports.
127128
['^\\u0000'],
128129
// Put same-folder imports, `..` and `.` last. Other relative imports.
129-
['^\\.\\.(?!/?$)', '^\\.\\./?$', '^\\./(?=.*/)(?!/?$)', '^\\.(?!/?$)', '^\\./?$',],
130+
['^\\.\\.(?!/?$)', '^\\.\\./?$', '^\\./(?=.*/)(?!/?$)', '^\\.(?!/?$)', '^\\./?$'],
130131
// Style imports.
131-
[ '^.+\\.?(css|scss)$'],
132+
['^.+\\.?(css|scss)$'],
132133
],
133134
},
134135
],

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@
7070
"devDependencies": {
7171
"@playwright/test": "^1.32.1",
7272
"@sentry/cli": "^2.2.0",
73+
"@tanstack/eslint-plugin-query": "<5",
7374
"@testing-library/jest-dom": "^5.16.2",
7475
"@testing-library/react": "^12.1.4",
7576
"@types/jest": "^27.4.1",

yarn.lock

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3537,6 +3537,15 @@ __metadata:
35373537
languageName: node
35383538
linkType: hard
35393539

3540+
"@tanstack/eslint-plugin-query@npm:<5":
3541+
version: 4.39.1
3542+
resolution: "@tanstack/eslint-plugin-query@npm:4.39.1"
3543+
peerDependencies:
3544+
eslint: ^6.0.0 || ^7.0.0 || ^8.0.0
3545+
checksum: 10c0/0bcc828fdbdc0c128bb3363353ebea51a243ce1cdd7650d8cd38e845f747488d3168539042cd14221fe183abaebcba4d09924fddcf0952b306697c2380c36dca
3546+
languageName: node
3547+
linkType: hard
3548+
35403549
"@tanstack/query-core@npm:4.40.0":
35413550
version: 4.40.0
35423551
resolution: "@tanstack/query-core@npm:4.40.0"
@@ -5721,6 +5730,7 @@ __metadata:
57215730
"@sentry/cli": "npm:^2.2.0"
57225731
"@sentry/integrations": "npm:7.50.0"
57235732
"@sentry/tracing": "npm:7.50.0"
5733+
"@tanstack/eslint-plugin-query": "npm:<5"
57245734
"@testing-library/jest-dom": "npm:^5.16.2"
57255735
"@testing-library/react": "npm:^12.1.4"
57265736
"@tippyjs/react": "npm:4.2.6"

0 commit comments

Comments
 (0)