Installation
Quick Setup
The recommended method for creating a Supex app is using create-supex
, which automatically sets up everything for you.
Terminal
npx create-supex@latest
This command create a folder with the project name and required config files.
Manual Installation
-
Install the required dependencies
Terminal
npm install supex@latest solid-js@latest webextension-polyfill@latest
-
Install the typescript dependencies. Skip this if you don't use typescript in your project;
Terminal
npm install typescript@latest @types/webextension-polyfill@latest --save-dev
-
Add the following scripts into package.json
package.json
{ "scripts": { "watch:chrome": "supex watch --browser=chrome", "watch:firefox": "supex watch --browser=chrome", "build": "supex build", "build:chrome": "supex build --browser=chrome", "build:firefox": "supex build --browser=chrome", "build:edge": "supex build --browser=edge", "build:opera": "supex build --browser=opera", "build:safari": "supex build --browser=safari", } }
-
Create a
supex.json
file and put the following attributessupex.json
{ "$schema": "https://supex.dev/schemas/config/0.0.1.json", "name": "Supex", "version": "0.0.1", } /* Please replace `name`, `version` and `description` values with your extension specific. */
-
Create
/app
and/public
folders.
Development Mode
To run your extension in development mode, please run npm run watch:chrome
or npm run watch:firefox
. This command will open a browser instance with the extension loaded.