Skip to content
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

Fix Conditional Typing in useSWRMutation to Allow Optional ExtraArg Without Explicitly Passing Undefined #2666

Merged
merged 6 commits into from
Jun 18, 2023
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
fix: delete unused test
  • Loading branch information
saengmotmi committed Jun 13, 2023
commit efbcdf6d42ac4dec86d8c7a47f26fb9998aa62de
3 changes: 0 additions & 3 deletions test/type/trigger.ts
Original file line number Diff line number Diff line change
@@ -94,9 +94,6 @@ export function useTestSWRMutation() {
)

const test = () => {
// @ts-expect-error `arg` should be 'foo'
trigger()

// @ts-expect-error `arg` should be 'foo'
trigger<typeof data>('bar', {
optimisticData: current => {