
Research
Security News
Lazarus Strikes npm Again with New Wave of Malicious Packages
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
@webextension-toolbox/webpack-webextension-plugin
Advanced tools
Webpack plugin that compiles web-extension manifest.json files and adds smart auto reload
Webpack plugin that compiles web-extension manifest.json
files and adds smart auto reload.
If you are looking for a simple CLI tool that utilizes this checkout https://github.com/webextension-toolbox/webextension-toolbox
manifest.json
fields$ npm i @webextension-toolbox/webextension-toolbox
import WebextensionPlugin from "@webextension-toolbox/webpack-webextension-plugin";
const config = {
plugins: [
new WebextensionPlugin({
vendor: "chrome",
}),
],
};
Add result to webpack plugins to initialize.
Type: Object
Any of the options below.
Type: String
Default: chrome
Any of: chrome
, opera
, firefox
, edge
, safari
Used for vendor prefixing in the manifest.json
. More infos regarding this can be found below.
Type: Integer
Default: 35729
Specify the listening port for the webstocket development server.
Type: Boolean
Default: true
Enables auto reload. If not specified will be enabled when using webpacks watch mode.
Type: Boolean
Default: false
Disable plugin logging.
Type: Integer
Default: 3000
Specify the reconnect time to the development server from the extension side.
Type: Object
Default: {}
Allows you to define defaults for the manifest.json
file.
Type: Boolean
Default: false
Skip Manifest Validation
We create/extend a background page or service worker in the extension with a websockets client if autoreload
is true the webpack is watch
ing, that connects to our custom websocket server.
As soon as a specific files changes the client checks how to reload the extension:
manifest.json
change → full reloadmanifest.json
dependencies change → full reload_locales
change → full reloadVendor prefixed manifest keys allow you to write one manifest.json
for multible vendors.
{
"__chrome__name": "SuperChrome",
"__firefox__name": "SuperFox",
"__edge__name": "SuperEdge",
"__opera__name": "SuperOpera",
"__safari__name": "SuperSafari"
}
if the vendor is chrome
this compiles to:
{
"name": "SuperChrome",
}
Add keys to multiple vendors by seperating them with | in the prefix
{
__chrome|opera__name: "SuperBlink"
}
if the vendor is chrome
or opera
, this compiles to:
{
"name": "SuperBlink"
}
{
"name": "__MY_ENV_VARIABLE__",
}
Would be replaced with the value of process.env.MY_ENV_VARIABLE
webpack-webextension-plugin
should work for every browser in the same way.web-ext
only works with Chrome and Firefox. You should definitely still check it out.Copyright 2018-2022 Henrik Wenz
This project is free software released under the MIT license.
[3.3.1] - 2024-01-07
FAQs
Webpack plugin that compiles web-extension manifest.json files and adds smart auto reload
The npm package @webextension-toolbox/webpack-webextension-plugin receives a total of 588 weekly downloads. As such, @webextension-toolbox/webpack-webextension-plugin popularity was classified as not popular.
We found that @webextension-toolbox/webpack-webextension-plugin demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
The Socket Research Team has discovered six new malicious npm packages linked to North Korea’s Lazarus Group, designed to steal credentials and deploy backdoors.
Security News
Socket CEO Feross Aboukhadijeh discusses the open web, open source security, and how Socket tackles software supply chain attacks on The Pair Program podcast.
Security News
Opengrep continues building momentum with the alpha release of its Playground tool, demonstrating the project's rapid evolution just two months after its initial launch.