Comments (3)
The [email protected]
udpdate axios to ^1.4.0 caused this problem, It appears to be a problem with create-react-app, as described in this GitHub issue: facebook/create-react-app#11889.
Since the issue is still open, some fixed pull requests have been submitted, but create-react-app (cra) has not yet adopted them.
It may be necessary to revert to [email protected]
until the aforementioned GitHub issue is resolved. In [email protected], [email protected]
is used, which does not have this problem.
from apisauce.
I also encountered the same error and found that axios
is a string after troubleshooting.
webpack 5.88
apisauce 3.0.1
node.js 16.13
![image](https://private-user-images.githubusercontent.com/21156871/258572993-140bb47d-c010-4e04-aefe-1296206a3763.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTg3MjcxMzksIm5iZiI6MTcxODcyNjgzOSwicGF0aCI6Ii8yMTE1Njg3MS8yNTg1NzI5OTMtMTQwYmI0N2QtYzAxMC00ZTA0LWFlZmUtMTI5NjIwNmEzNzYzLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA2MTglMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNjE4VDE2MDcxOVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWFjMDRmNzhjOTA1YWZlNmE2M2UxMDc0OGIzNWY4NTc3OWJhZDJkZGE1ZGEwMzJhYmYxOTQxMmZmMjIzODFkZmImWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.feHRHCShvhaemxlIyFyoi6gBAD9_aDxnYsMCG3go9us)
![image](https://private-user-images.githubusercontent.com/21156871/258573026-0abcc462-1377-4095-a3cf-3dfad72537c5.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTg3MjcxMzksIm5iZiI6MTcxODcyNjgzOSwicGF0aCI6Ii8yMTE1Njg3MS8yNTg1NzMwMjYtMGFiY2M0NjItMTM3Ny00MDk1LWEzY2YtM2RmYWQ3MjUzN2M1LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA2MTglMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNjE4VDE2MDcxOVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTkwNTJkMzc0NmNlYzU3MWU1MDU4NmQzM2QzN2EwZGZlMzFmODg1ZGU1ZmUzMDA5MGNmODk5MjY5NjFkM2YzNjEmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.yj9pKU4hD9zx4hDOSmdoSVuu_sYXFy7HI1V9QIkeHHc)
After webpack bundling, the axios is compiled into:
I suspect it could be an issue with how webpack handles dependencies or there might be an issue with the exports in the axios package's configuration file.
from apisauce.
Same problem here while upgrading from 2.0 to 3.0.1 on a Create React App project (webpack). It seems to be a problem with a certain version of axios that does not export properly the create()
function, see axios/axios#5613 and axios/axios#5038. I'm very interested in any workaround. 🙏
from apisauce.
Related Issues (20)
- Retry with new config HOT 1
- Cannot read properties of undefined (reading 'status') HOT 7
- Request sends Twice returns HTTP 500 Error HOT 2
- doesn't support formData HOT 4
- How to add file CA Certificate https?
- Question about response type declaration HOT 5
- Vulnerability introduced by package follow-redirects HOT 1
- Do I Need To Set Headers Max-Age?
- is there any schedule to upgrade the axios? HOT 4
- Latest version support for Axios ? HOT 2
- addAsyncRequestTransform not tiggering in iOS
- Remove request/response transform. HOT 1
- got 2 test case failed in unit test HOT 1
- Upload image not working on 3.0.1 HOT 3
- error TypeError: axios.isCancel is not a function HOT 1
- create is not a function HOT 3
- Weird behaviour with urls after updating to Xcode 15 HOT 6
- Is there a way to redo a request if failed?
- axiosInstance doesn't inherit default headers from apisauce
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from apisauce.