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

Add third parameter with response to trace and allow it to be asynchronous #53

Merged
merged 4 commits into from
Aug 2, 2024

Conversation

diogob
Copy link
Collaborator

@diogob diogob commented Aug 1, 2024

No description provided.

…ype make it easier to write callbacks without having to check optional values. It is backwards compatible,
@diogob diogob marked this pull request as ready for review August 1, 2024 21:15
…s not necessarly what fetch receives. The same applies to the second parameter.
src/types.ts Outdated
trace?: (
fullUrl: string | URL,
init: EnhancedRequestInit,
response: Awaited<ReturnType<typeof fetch>>,
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Couldn't you use TypedResponse type here?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sure, let me try

@gustavoguichard gustavoguichard merged commit 7af935b into main Aug 2, 2024
1 check passed
@gustavoguichard gustavoguichard deleted the async-trace-with-response branch August 2, 2024 14:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants