Skip to content

Commit

Permalink
docs: add es6 example
Browse files Browse the repository at this point in the history
  • Loading branch information
jasonsaayman authored Oct 28, 2024
1 parent cda671a commit 76dc3e6
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,12 @@ const axios = require('axios');
console.log(axios.isCancel('something'));
```

For some bundlers and some ES6 linter's you may need to do the following:
```js
import { default as axios } from 'axios';
```
For cases where something went wrong when trying to import a module into a custom or legacy environment,
you can try importing the module package directly:
Expand Down

0 comments on commit 76dc3e6

Please sign in to comment.