Skip to content

Commit

Permalink
We need a more precise type for the fullURL since the value we pass i…
Browse files Browse the repository at this point in the history
…s not necessarly what fetch receives. The same applies to the second parameter (with the exception of body that perhaps can be coerced by the caller)
  • Loading branch information
diogob committed Aug 1, 2024
1 parent 499e6cf commit 0a8761c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ type EnhancedRequestInit<T = string> = Omit<RequestInit, 'body' | 'method'> & {
query?: SearchParams
params?: PathParams<T>
trace?: (
input: Parameters<typeof fetch>[0],
init: Parameters<typeof fetch>[1],
fullUrl: string | URL,
init: EnhancedRequestInit & { body: unknown },
response: Awaited<ReturnType<typeof fetch>>,
) => void | Promise<void>
}
Expand Down

0 comments on commit 0a8761c

Please sign in to comment.