TS error:
Argument type UseQueryOptions<T, Register extends {defaultError: infer TError} ? TError : Error, T, string[]> & {initialData?: undefined} & {queryKey: DataTag<string[], T>} is not assignable to parameter type FetchQueryOptions<[T][T extends any ? 0 : never] & T, Register extends {defaultError: infer TError} ? TError : Error, T, QueryKey>
I would not know what are details are necessary but it seems like
lightsListQueryOptions
does not implement correctly FetchQueryOptions



5 Replies
other-emeraldOP•2y ago
this is just a rewriting of it is shown here: https://tanstack.com/router/v1/docs/examples/react/basic-react-query-file-based.
React Router Basic React Query File Based. Example | TanStack Route...
An example showing how to implement Basic React Query File Based. in React Router
solid-orange•2y ago
please create a typescript playground
other-emeraldOP•2y ago
https://stackblitz.com/edit/vitejs-vite-vkaept?file=package.json
my editor highlights different problems to stackblitz editor. running
tsc
also highlight different problems, being tsconfig the same nonetheless
code works fine after all but was curious too understand the type issue my editor raisesfascinating-indigo•2y ago
TS Playground - An online editor for exploring TypeScript and JavaS...
The Playground lets you write TypeScript or JavaScript online in a safe and sharable way.
other-emeraldOP•2y ago
should I just ignore my editor's errors? I am using webstorm