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

Issue-13: Make parse optional #14

Closed
wants to merge 2 commits into from
Closed

Issue-13: Make parse optional #14

wants to merge 2 commits into from

Conversation

chrstnfrrs
Copy link
Contributor

Closes: #13

Description
This PR aims to make parsing optional.

  • It creates a new object to pass through as options, setting parse to true and then spreading consumer options. This will overwrite the parse set to true, if parse is passed through.
  • If parse is set, then it parses the JSON body and automatically adds headers. If parse is set to false, then body is maintained and headers are not changed.
  • Parse is added to the FetchOptions type as an optional boolean.

@chrstnfrrs
Copy link
Contributor Author

I misunderstood what the Issue was requesting. This solution is incorrect and I will open a new :pr: with the correct solution.

@chrstnfrrs chrstnfrrs closed this Sep 16, 2021
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.

Make parse optional
1 participant