Skip to content

refactor(query-core): remove unused common type #8989

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

Merged
merged 6 commits into from
May 1, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
refactor: remove unused common type
  • Loading branch information
novice0840 committed Apr 20, 2025
commit 4de190abfe0479cce7f8fba0dc3715a34ee7c6ec
7 changes: 1 addition & 6 deletions packages/query-core/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -430,13 +430,8 @@ export interface QueryObserverOptions<
}

export type WithRequired<TTarget, TKey extends keyof TTarget> = TTarget & {
[_ in TKey]: {}
[K in TKey]-?: TTarget[K]
}
export type Optional<TTarget, TKey extends keyof TTarget> = Pick<
Partial<TTarget>,
TKey
> &
Omit<TTarget, TKey>

export type DefaultedQueryObserverOptions<
TQueryFnData = unknown,
Expand Down
Loading