Preact

Adds a sidebar panel to the browser with a simple Preact page.

Runs on Chrome, Edge, Firefox · Manifest V3 · Surfaces: sidebar, content script, popup, background service worker · Styling: CSS · Level: beginner · Framework: preact

Create this project

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

What it is for

  • A sidebar panel rendered by Preact
  • Preact and JSX compiled with no extra config
  • Starting point for Preact extensions

First steps

  • Run npm run dev to launch the extension
  • Click the extension icon to open the Preact sidebar panel
  • Edit the component in src/sidebar/ to see fast refresh update it

Permissions it asks for

  • sidePanel

extension.devDocumentation for extension.dev