Content scripts with Sass

Injects a small styled badge into every web page you visit, with a Sass options page that moves it to the left or right edge.

Runs on Chrome, Edge, Firefox · Manifest V3 · Surfaces: content script, options page, background service worker · Styling: Sass · Level: beginner

Create this project

npx extension@latest create my-content-sass --template content-sass
cd my-content-sass
npm install
npm run dev

Files in this template

  • extension.config.js
  • src/background.js
  • src/content/scripts.js
  • src/content/styles.scss
  • src/images/icon.png
  • src/manifest.json
  • src/options/index.html
  • src/options/scripts.js
  • src/options/styles.scss

extension.devDocumentation for extension.dev