stackblitz / core

Online IDE powered by Visual Studio Code ⚡️
https://stackblitz.com
MIT License
10.26k stars 892 forks source link

Importing Axios for snippet testing #2937

Closed darthleonard closed 2 months ago

darthleonard commented 8 months ago

Refering from 2687

Axios & whateaver is gaxios fail same way

Downgrading axios to 0.16.2 does not work as commented on 2722

Tested with the Angular starter project too, same issue

Failing code(commented and uncommented lines): imagen

StackBlitz project reproducing the issue: https://stackblitz.com/edit/ionic6-angular13-bb3xgm?file=src%2Fapp%2Fapp.component.ts

HeyGarrison commented 8 months ago

👋 Hey there!

Could you try converting you project to a WebContainer project? Here is a starter: https://node.new

One thing to note is that external HTTP Requests inside of StackBlitz are kind of tricky. Most of the time the requests end up getting CORS errors. We're going to introduce a new feature for this soon, but for the time being it is a constraint.

Hope that helps!