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(types): allow narrowing of the method option in NitroFetchOptions #883

Merged
merged 2 commits into from
Jan 31, 2023

Conversation

dsluijk
Copy link
Contributor

@dsluijk dsluijk commented Jan 25, 2023

πŸ”— Linked issue

❓ Type of change

  • πŸ“– Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • πŸ‘Œ Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

πŸ“š Description

This PR allows you to enhance the Nitro fetch method by providing this in a generic.

This change is needed to allow nuxt/nuxt#15280 to be fixed.

πŸ“ Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

@codecov
Copy link

codecov bot commented Jan 25, 2023

Codecov Report

Merging #883 (ac4c489) into main (6596c5f) will increase coverage by 0.03%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main     #883      +/-   ##
==========================================
+ Coverage   67.47%   67.50%   +0.03%     
==========================================
  Files          59       59              
  Lines        5860     5866       +6     
  Branches      635      637       +2     
==========================================
+ Hits         3954     3960       +6     
  Misses       1897     1897              
  Partials        9        9              
Impacted Files Coverage Ξ”
src/types/fetch.ts 100.00% <100.00%> (ΓΈ)
src/prerender.ts 89.34% <0.00%> (+0.14%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

src/types/fetch.ts Outdated Show resolved Hide resolved
@danielroe danielroe changed the title Allow for futher narrowing of the method option feat: allow futher narrowing of the method option in NitroFetchOptions Jan 31, 2023
@danielroe danielroe requested a review from pi0 January 31, 2023 14:06
@pi0 pi0 changed the title feat: allow futher narrowing of the method option in NitroFetchOptions fix(types): allow narrowing of the method option in NitroFetchOptions Jan 31, 2023
Copy link
Member

@pi0 pi0 left a comment

Choose a reason for hiding this comment

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

Thanks all!

@pi0 pi0 merged commit a12e1e7 into unjs:main Jan 31, 2023
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.

None yet

4 participants