Setting Up Mellowtel with Firefox Extensions
This guide will walk you through integrating Mellowtel into your Firefox extension, supporting both Manifest V2 and V3.
Installation
First, install the Mellowtel npm package:
Manifest Configuration
The manifest.json
file needs specific configurations for Mellowtel to work properly. Here are the required parts for both Manifest V2 and V3:
Manifest V2
Manifest V3
Background Script Setup
Create a file named background.js
with the following content:
Replace <your_configuration_key>
with your actual Mellowtel configuration key.
Content Script Setup
Create a file named content_start_mellowtel.js
with the following content:
Again, replace <your_configuration_key>
with your actual Mellowtel configuration key.
Popup for Mellowtel Settings
To allow users to access Mellowtel settings easily, you should create a popup. Here’s how to set it up:
- Create a
popup.html
file:
- Create a
popup.js
file:
Remember to replace <your_configuration_key>
with your actual Mellowtel configuration key.