Skip to content

Commit bd3296b

Browse files
chore: Update @tanstack/config to v0.11.0 (#7795)
1 parent 1814f56 commit bd3296b

File tree

19 files changed

+203
-52
lines changed

19 files changed

+203
-52
lines changed

eslint.config.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ export default [
3535
},
3636
},
3737
],
38-
'ts/ban-types': 'off',
39-
'ts/no-empty-function': 'off',
38+
'@typescript-eslint/ban-types': 'off',
39+
'@typescript-eslint/no-empty-function': 'off',
4040
'no-case-declarations': 'off',
4141
},
4242
},

examples/react/offline/public/mockServiceWorker.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
/* eslint-disable */
2-
/* tslint:disable */
32

43
/**
54
* Mock Service Worker (2.1.7).

examples/solid/solid-start-streaming/src/components/query-boundary.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
/* eslint-disable @typescript-eslint/no-non-null-assertion */
2-
31
import type { CreateQueryResult } from '@tanstack/solid-query'
42
import type { JSX } from 'solid-js'
53
import { ErrorBoundary, Match, Suspense, Switch, children } from 'solid-js'

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
"@cspell/eslint-plugin": "^8.9.1",
4242
"@eslint-react/eslint-plugin": "^1.5.16",
4343
"@solidjs/testing-library": "^0.8.8",
44-
"@tanstack/config": "^0.10.0",
44+
"@tanstack/config": "^0.11.0",
4545
"@testing-library/jest-dom": "^6.4.6",
4646
"@testing-library/react": "^16.0.0",
4747
"@types/eslint": "^8.56.10",

packages/angular-query-experimental/src/util/create-injection-token/create-injection-token.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ export function createNoopInjectionToken<
169169
type TReturn = TMulti extends true ? Array<TValue> : TValue
170170

171171
const token =
172-
// eslint-disable-next-line ts/no-unnecessary-condition
172+
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
173173
(options as CreateInjectionTokenOptions<() => void, []>)?.token ||
174174
new InjectionToken<TReturn>(description)
175175
return [

packages/eslint-plugin-query/src/utils/ast-utils.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -249,9 +249,9 @@ export const ASTUtils = {
249249
const { node, context } = params
250250

251251
// we need the fallbacks for backwards compat with eslint < 8.37.0
252-
// eslint-disable-next-line ts/no-unnecessary-condition
252+
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
253253
const sourceCode = context.sourceCode ?? context.getSourceCode()
254-
// eslint-disable-next-line ts/no-unnecessary-condition
254+
// eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
255255
const scope = context.sourceCode.getScope(node)
256256
? sourceCode.getScope(node)
257257
: context.getScope()

packages/query-codemods/eslint.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ export default [
77
{
88
rules: {
99
'cspell/spellchecker': 'off',
10-
'ts/no-unnecessary-condition': 'off',
10+
'@typescript-eslint/no-unnecessary-condition': 'off',
1111
'import/no-duplicates': 'off',
1212
'import/no-unresolved': 'off',
1313
'import/order': 'off',

packages/query-core/src/__tests__/notifyManager.test.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,12 +74,12 @@ describe('notifyManager', () => {
7474
// we define some fn with its signature:
7575
const fn: (a: string, b: number) => string = (a, b) => a + b
7676

77-
//now someFn expect to be called with args [a: string, b: number]
77+
// now someFn expect to be called with args [a: string, b: number]
7878
const someFn = notifyManagerTest.batchCalls(fn)
7979

8080
someFn('im happy', 4)
8181

82-
//@ts-expect-error
82+
// @ts-expect-error
8383
someFn('im not happy', false)
8484
})
8585
})

packages/query-core/src/__tests__/onlineManager.test.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ describe('onlineManager', () => {
1212
const navigatorSpy = vi.spyOn(globalThis, 'navigator', 'get')
1313

1414
// Force navigator to be undefined
15-
//@ts-expect-error
15+
// @ts-expect-error
1616
navigatorSpy.mockImplementation(() => undefined)
1717
expect(onlineManager.isOnline()).toBeTruthy()
1818

packages/query-core/src/__tests__/queryObserver.test.tsx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ describe('queryObserver', () => {
9696

9797
queryClient.invalidateQueries({ queryKey: key, refetchType: 'all' })
9898

99-
//So we still expect it to not have fetched and not be fetching
99+
// So we still expect it to not have fetched and not be fetching
100100
expect(count).toBe(0)
101101
expect(observer.getCurrentResult()).toMatchObject({
102102
status: 'pending',
@@ -113,7 +113,7 @@ describe('queryObserver', () => {
113113

114114
expect(enabled).toBe(false)
115115

116-
//Not the same with explicit refetch, this will override enabled and trigger a fetch anyway
116+
// Not the same with explicit refetch, this will override enabled and trigger a fetch anyway
117117
observer.refetch()
118118

119119
expect(observer.getCurrentResult()).toMatchObject({
@@ -201,18 +201,18 @@ describe('queryObserver', () => {
201201

202202
queryClient.invalidateQueries({ queryKey: key, refetchType: 'inactive' })
203203

204-
//should not refetch since it was active and we only refetch inactive
204+
// should not refetch since it was active and we only refetch inactive
205205
await waitFor(() => expect(count).toBe(0))
206206

207207
queryClient.invalidateQueries({ queryKey: key, refetchType: 'active' })
208208

209-
//should refetch since it was active and we refetch active
209+
// should refetch since it was active and we refetch active
210210
await waitFor(() => expect(count).toBe(1))
211211

212212
// Toggle enabled
213213
enabled = false
214214

215-
//should not refetch since it is not active and we only refetch active
215+
// should not refetch since it is not active and we only refetch active
216216
queryClient.invalidateQueries({ queryKey: key, refetchType: 'active' })
217217

218218
await waitFor(() => expect(count).toBe(1))
@@ -792,7 +792,7 @@ describe('queryObserver', () => {
792792
new QueryObserver(queryClient, {
793793
queryKey: key,
794794
queryFn: () => 'data',
795-
//@ts-expect-error
795+
// @ts-expect-error
796796
enabled: null,
797797
}),
798798
).toThrowError('Expected enabled to be a boolean')
@@ -947,7 +947,7 @@ describe('queryObserver', () => {
947947
observer.setOptions({
948948
queryKey: key,
949949
queryFn: () => data,
950-
//@ts-expect-error
950+
// @ts-expect-error
951951
select: () => undefined,
952952
placeholderData: placeholderData2,
953953
})

0 commit comments

Comments
 (0)