Skip to content

Comments

Allow to omit init arg of fetch#162

Merged
mpppk merged 2 commits intomainfrom
optional-fetch-init
Apr 5, 2025
Merged

Allow to omit init arg of fetch#162
mpppk merged 2 commits intomainfrom
optional-fetch-init

Conversation

@mpppk
Copy link
Collaborator

@mpppk mpppk commented Apr 5, 2025

This pull request includes changes to the pkgs/typed-api-spec package, focusing on enhancing the fetch module's flexibility and correctness. The most important changes involve extending type definitions and updating test cases to reflect these improvements.

Enhancements to type definitions:

  • pkgs/typed-api-spec/src/fetch/index.ts: Added Headers and Body type parameters to the FetchT type and introduced CanOmitMethod and CanOmitInit boolean type parameters to determine if the init parameter can be omitted based on method and headers conditions. [1] [2]

Updates to test cases:

@mpppk mpppk merged commit fb3f9a9 into main Apr 5, 2025
3 checks passed
@mpppk mpppk deleted the optional-fetch-init branch April 5, 2025 03: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.

1 participant