Axios is not using async/await. Your code do that and it's JavaScript, the same is with native fetch. async/await is syntax sugar for promises that is not part of Axios it's part of JavaScript. Axios is just using promises it don't uses async/await. So the same will be with any library that use promises.
Here is example of native fetch API:
varres=awaitfetch('url');vardata=awaitres.json();
see you also don't need to use .then(), this have nothing to do with axios.
Axios is not using async/await. Your code do that and it's JavaScript, the same is with native fetch. async/await is syntax sugar for promises that is not part of Axios it's part of JavaScript. Axios is just using promises it don't uses async/await. So the same will be with any library that use promises.
Here is example of native fetch API:
see you also don't need to use
.then()
, this have nothing to do with axios.I see, I appreciate your explanation on the topic!