Https://www.unpkg.com/moralis-v1/package.json - Web server is returning an unknown error

Hello,

As of today I am getting CORS errors related to missing package.json file. The file seems to be missing, unpkg.com display the following message: Web server is returning an unknown error.

My application uses : <script src="https://unpkg.com/[email protected]/dist/moralis.js"></script>

Access to XMLHttpRequest at 'https://www.unpkg.com/moralis-v1/package.json' from origin 'http://127.0.0.1:5173' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource.```

does it work with a different package provider?
it could be an issue on unpkg side?

this url works fine for me to access it

Yes that url is working but https://www.unpkg.com/moralis-v1/package.json is not there, and it’s being called within the script.

Is there another official Moralis package provider?

you can use this url

https://cdn.jsdelivr.net/npm/moralis-v1/package.json

The problem is that package.json url is hard-coded inside moralis.js file that is hosted on unpkg. Also https://cdn.jsdelivr.net/npm/moralis-v1/dist/moralis.js is pointing to the same missing file https://www.unpkg.com/moralis-v1/package.json.

I tried installing Moralis-v1 SDK but moralis.js is also pointing to the same missing file on unpkg.

All roads lead to unpkg.

now it looks like this url works

https://www.unpkg.com/moralis-v1/package.json

Yep, it’s working again. :tada:

1 Like