# Unable to load the auth-spa-js script inside chrome extension

**URL:** <https://community.auth0.com/t/unable-to-load-the-auth-spa-js-script-inside-chrome-extension/94165>\
**Category:** Get Help\
**Tags:** chrome-extension, api, javascript, login, auth0\
**Created:** [November 10, 2022, 1:12pm UTC](https://community.auth0.com/t/unable-to-load-the-auth-spa-js-script-inside-chrome-extension/94165 "2022-11-10T13:12:05Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![kumarayush6543](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/kumarayush6543/32/33811_2.png) [@kumarayush6543](https://community.auth0.com/u/kumarayush6543)\
**Post date:** [November 10, 2022, 1:12pm UTC](https://community.auth0.com/t/unable-to-load-the-auth-spa-js-script-inside-chrome-extension/94165/1 "2022-11-10T13:12:05Z")

</div>

Hi, I have been trying to load the script file of auth-spa-js, but it shows the error.

```auto
index.html:1 
     
       Refused to load the script 'https://cdn.auth0.com/js/auth0-spa-js/1.2/auth0-spa-js.production.js' because it violates the following Content Security Policy directive: "script-src 'self' 'wasm-unsafe-eval'". Note that 'script-src-elem' was not explicitly set, so 'script-src' is used as a fallback.

```

I am developing this app using manifest\_version: 3  
Here is the manifest.json

```auto
{
  "name": "Chrome extension",
  "version": "1.0.0",
  "description": "",
  "manifest_version": 3,
  "author": "Ayush kumar",
  "action": {
    "default_popup": "index.html",
    "default_title": "Chrome extension"
  },
  "background": {
    "service_worker": "background.js",
    "type": "module"
  },

  "permissions": ["storage", "cookies"],
  "host_permissions": ["http://*/*", "https://*/*"]
}

```

---

<div class="post-metadata">

**Author:** ![kumarayush6543](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/kumarayush6543/32/33811_2.png) [@kumarayush6543](https://community.auth0.com/u/kumarayush6543)\
**Post date:** [November 10, 2022, 1:21pm UTC](https://community.auth0.com/t/unable-to-load-the-auth-spa-js-script-inside-chrome-extension/94165/2 "2022-11-10T13:21:10Z")

</div>

Ok, I found a link to v3 which says, that remote codes can no longer be hosted. So it’s better to download the minified versions. [https://developer.chrome.com/docs/extensions/mv3/mv3-migration/#remotely-hosted-code](https://developer.chrome.com/docs/extensions/mv3/mv3-migration/#remotely-hosted-code)

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [September 7, 2024, 12:49am UTC](https://community.auth0.com/t/unable-to-load-the-auth-spa-js-script-inside-chrome-extension/94165/3 "2024-09-07T00:49:37Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
