Socket
Socket
Sign inDemoInstall

wext-manifest-webpack-plugin

Package Overview
Dependencies
1
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

wext-manifest-webpack-plugin


Version published
Weekly downloads
648
decreased by-11.48%
Maintainers
1
Install size
244 kB
Created
Weekly downloads
 

Readme

Source

wext-manifest-webpack-plugin

Webpack plugin to solve the problem of generating js file for manifest.json entry

NPM Travis Build DEPENDENCIES LICENSE TWEET

🙋‍♂️ Made by @abhijithvijayan

Donate: PayPal, Patreon

Buy Me a Coffee


❤️ it? ⭐️ it on GitHub or Tweet about it.

Table of Contents

How it works

It just find js files from manifest entry and remove the js file from the compilation.

Looking for Web Extension starter

Checkout web-extension-starter that uses this plugin

Installation

# npm
npm install --save-dev wext-manifest-webpack-plugin

# yarn
yarn add wext-manifest-webpack-plugin --dev

Usage

// ... other plugins
const WextManifestWebpackPlugin = require("wext-manifest-webpack-plugin");

module.exports = {
    entry: {
        manifest: './source/manifest.json',
        // ...
    },

    output: {
        path: path.join(destPath, targetBrowser),
        filename: 'js/[name].js',
    },

    module: {
        rules: [
            {
                type: 'javascript/auto', // prevent webpack handling json with its own loaders,
                test: /manifest\.json$/,
                use: 'wext-manifest-loader',
                exclude: /node_modules/,
            },
        ]
    },

    plugins: [
        new WextManifestWebpackPlugin(),
        // ...
    ],
};

Issues

Looking to contribute? Look for the Good First Issue label.

🐛 Bugs

Please file an issue here for bugs, missing documentation, or unexpected behavior.

See Bugs

Linting & TypeScript Config

License

MIT © Abhijith Vijayan

Keywords

FAQs

Last updated on 02 Jul 2020

Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc