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(type): add AxiosError to AxiosStatic #4654

Merged
merged 3 commits into from May 3, 2022

Conversation

michael-land
Copy link
Contributor

https://github.com/axios/axios/blob/master/lib/axios.js#L47

Instructions

Please read and follow the instructions before creating and submitting a pull request:

  • Create an issue explaining the feature. It could save you some effort in case we don't consider it should be included in axios.
  • If you're fixing a bug, try to commit the failing test/s and the code fixing it in different commits.
  • Ensure you're following our contributing guide.

⚠️👆 Delete the instructions before submitting the pull request 👆⚠️

Describe your pull request here.

Copy link
Member

@jasonsaayman jasonsaayman left a comment

Choose a reason for hiding this comment

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

Thanks for the pull request

@jasonsaayman jasonsaayman merged commit 8213da4 into axios:master May 3, 2022
@enapupe
Copy link

enapupe commented May 11, 2022

Can we see that into a release? ❤️

@GuichiZhao
Copy link

It is not a good idea, "Class" is sort of specially in typescript, it can be used as both type and value, by putting AxiosError as static, there is no way to use AxiosError as type. On the other hand, by import {AxiosError} from 'axios' there is no way to use AxiosError as value

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