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 custom HTTP client documentation #10

Merged
merged 3 commits into from
Dec 4, 2021

Conversation

0x62
Copy link
Contributor

@0x62 0x62 commented Nov 24, 2021

Just seen the updated documentation suggested using axios as an alternative fetch instance which does not support the Fetch API. I've changed this to use a node-fetch example instead.

ismailuddin and others added 3 commits November 23, 2021 22:28
Previous documentation suggested using `axios` which does not support the Fetch API
@ismailuddin ismailuddin changed the base branch from main to dev November 27, 2021 18:15
@ismailuddin ismailuddin added the documentation Improvements or additions to documentation label Nov 27, 2021
@ismailuddin
Copy link
Contributor

That's technically correct, but it is still possible to swap in axios which I guess supports a Fetch-like API? I'd like to just add in a line mentioning adding axios does work as well. I think you haven't enabled edits for this PR, so I can't make the change myself...

@0x62
Copy link
Contributor Author

0x62 commented Dec 2, 2021

As far as I'm aware a Fetch-like API is planned for axios but hasn't launched yet [0][1]. I'd be very surprised if substituting axios directly like this works as it uses axios[method] rather than specifying the HTTP method in the arguments.

[0] axios/axios#4209
[1] https://trello.com/b/SBqOxCst/axios-next

@ismailuddin
Copy link
Contributor

Yup you're right, I think I hadn't re-compiled the TS to JS when I tested it with JS.

@ismailuddin ismailuddin merged commit fb9621e into hybiscus-dev:dev Dec 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants