0.1.5 • Published 5 years ago
rollup-plugin-webext-manifest v0.1.5
rollup-plugin-webext-manifest
Theoretically a Rollup plugin for processing web extension manifest files.
Installation
# With Yarn
yarn add --dev rollup-plugin-webext-manifest
# With npm
npm install --save-dev rollup-plutin-webext-manifestUsage
Add a configuration object to your rollup.config.js that takes your manifest.json as its only input. Include this module as the first plugin in your configuration. Set targetPlatform to one of chrome (Chrome) or gecko (Firefox). Minimal example:
// rollup.config.js
import processManifest from 'rollup-plugin-webext-manifest';
export default [
  {
    input: 'manifest.json',
    plugins: [
      processManifest({
        targetPlatform: 'gecko',
      }),
    ],
    output: {
      dir: 'build',
    },
  },
];TODO: document other options