Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

CSS Not loading in chrome extension

I'm trying to inject custom css onto a website. I keep getting a error message

Failed to load extension
File
C:\Users\username\Desktop\Mineplex+
ErrorCould not load css '' for content script.

manifest.js:

  "name": "Mineplex+",
  "author": "UCYT5040",
  "version": "1.0",
  "manifest_version": 3,
  "background": {
    "service_worker": "background.js"
  },
  "permissions": ["scripting", "tabs", "https://*.mineplex.com", "http://*.mineplex.com/*"],
  "content_scripts": [
    {
      "matches": ["https://*.mineplex.com/*"], 
      "css" : ["https://Better-Mineplex-Forums.ucyt5040.repl.co/style.css"]
    }
    ],
  "action": {}
}
like image 849
UCYT5040 Avatar asked Jul 23 '26 09:07

UCYT5040


1 Answers

@wOxxOM answered as a comment.

css should contain a local path inside the extension, not an external URL. Download style.css and place it inside the extension, then specify style.css in css key.

like image 182
UCYT5040 Avatar answered Jul 25 '26 23:07

UCYT5040



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!