Skip to content

Commit

Permalink
chore(deps): update to @tanstack/config 0.13.1 (TanStack#7986)
Browse files Browse the repository at this point in the history
* chore(deps): update to @tanstack/config 0.13.1

* Fix types
  • Loading branch information
lachlancollins authored and KATT committed Sep 1, 2024
1 parent 494ed98 commit 57dcd08
Show file tree
Hide file tree
Showing 13 changed files with 128 additions and 397 deletions.
2 changes: 1 addition & 1 deletion eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ export default [
},
},
],
'@typescript-eslint/ban-types': 'off',
'@typescript-eslint/no-empty-function': 'off',
'@typescript-eslint/no-unsafe-function-type': 'off',
'no-case-declarations': 'off',
},
},
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@
"@cspell/eslint-plugin": "^8.14.2",
"@eslint-react/eslint-plugin": "^1.12.3",
"@solidjs/testing-library": "^0.8.9",
"@tanstack/config": "^0.11.1",
"@tanstack/config": "^0.13.1",
"@testing-library/jest-dom": "^6.4.8",
"@testing-library/react": "^16.0.0",
"@types/eslint": "^9.6.1",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,15 @@ import { InjectOptions } from '@angular/core';
import { Injector } from '@angular/core';
import type { MutateFunction } from '@tanstack/query-core';
import type { Mutation } from '@tanstack/query-core';
import { MutationFilters } from '@tanstack/query-core';
import type { MutationFilters } from '@tanstack/query-core';
import type { MutationObserverOptions } from '@tanstack/query-core';
import type { MutationObserverResult } from '@tanstack/query-core';
import type { MutationState } from '@tanstack/query-core';
import type { OmitKeyof } from '@tanstack/query-core';
import { Provider } from '@angular/core';
import type { QueriesPlaceholderDataFunction } from '@tanstack/query-core';
import type { QueryClient } from '@tanstack/query-core';
import { QueryFilters } from '@tanstack/query-core';
import type { QueryFilters } from '@tanstack/query-core';
import type { QueryFunction } from '@tanstack/query-core';
import type { QueryKey } from '@tanstack/query-core';
import type { QueryObserverOptions } from '@tanstack/query-core';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
import {
type InputSignal,
type Signal,
isSignal,
untracked,
} from '@angular/core'
import { isSignal, untracked } from '@angular/core'
import { SIGNAL, signalSetFn } from '@angular/core/primitives/signals'
import type { InputSignal, Signal } from '@angular/core'
import type { ComponentFixture } from '@angular/core/testing'

let queryKeyCount = 0
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import { DestroyRef, NgZone, inject, signal } from '@angular/core'
import { type QueryFilters, notifyManager } from '@tanstack/query-core'
import { notifyManager } from '@tanstack/query-core'
import { assertInjector } from './util/assert-injector/assert-injector'
import { injectQueryClient } from './inject-query-client'
import type { QueryFilters } from '@tanstack/query-core'
import type { Injector, Signal } from '@angular/core'

/**
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import { DestroyRef, NgZone, inject, signal } from '@angular/core'
import { type MutationFilters, notifyManager } from '@tanstack/query-core'
import { notifyManager } from '@tanstack/query-core'
import { assertInjector } from './util/assert-injector/assert-injector'
import { injectQueryClient } from './inject-query-client'
import type { MutationFilters } from '@tanstack/query-core'
import type { Injector, Signal } from '@angular/core'

/**
Expand Down
1 change: 1 addition & 0 deletions packages/query-core/src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -305,6 +305,7 @@ export function isPlainArray(value: unknown) {
}

// Copied from: https://github.com/jonschlinkert/is-plain-object
// eslint-disable-next-line @typescript-eslint/no-wrapper-object-types
export function isPlainObject(o: any): o is Object {
if (!hasObjectPrototype(o)) {
return false
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { describe, expectTypeOf, it } from 'vitest'
import { QueryClient } from '@tanstack/query-core'
import { type InfiniteData, dataTagSymbol } from '@tanstack/query-core'
import { QueryClient, dataTagSymbol } from '@tanstack/query-core'
import { infiniteQueryOptions } from '../infiniteQueryOptions'
import { useInfiniteQuery } from '../useInfiniteQuery'
import { useSuspenseInfiniteQuery } from '../useSuspenseInfiniteQuery'
import type { InfiniteData } from '@tanstack/query-core'

describe('queryOptions', () => {
it('should not allow excess properties', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
import { describe, expectTypeOf, it } from 'vitest'
import { type InfiniteData, dataTagSymbol } from '@tanstack/query-core'
import { dataTagSymbol } from '@tanstack/query-core'
import { createInfiniteQuery } from '../createInfiniteQuery'
import { infiniteQueryOptions } from '../infiniteQueryOptions'
import type { InfiniteData } from '@tanstack/query-core'
import type {
DefinedInitialDataInfiniteOptions,
UndefinedInitialDataInfiniteOptions,
Expand Down
3 changes: 2 additions & 1 deletion packages/solid-query/src/isRestoring.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { type Accessor, createContext, useContext } from 'solid-js'
import { createContext, useContext } from 'solid-js'
import type { Accessor } from 'solid-js'

const IsRestoringContext = createContext<Accessor<boolean>>(() => false)

Expand Down
1 change: 0 additions & 1 deletion packages/vue-query/src/devtools/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import type { Query } from '@tanstack/query-core'

type SortFn = (a: Query, b: Query) => number

// eslint-disable-next-line no-shadow
enum QueryState {
Fetching = 0,
Fresh,
Expand Down
1 change: 1 addition & 0 deletions packages/vue-query/src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ export function cloneDeepUnref<T>(
})
}

// eslint-disable-next-line @typescript-eslint/no-wrapper-object-types
function isPlainObject(value: unknown): value is Object {
if (Object.prototype.toString.call(value) !== '[object Object]') {
return false
Expand Down
Loading

0 comments on commit 57dcd08

Please sign in to comment.