0.0.6 • Published 6 years ago

webpack-reload-extension v0.0.6

Weekly downloads
8
License
MIT
Repository
github
Last release
6 years ago

webpack-reload-extension

Webpack plugin that auto reloads chrome extensions.

Installation

$ npm i -D webpack-reload-extension

Usage

You need a content script and a background script for this plugin to work.

Only works when mode is set to development.

Options

OptionDescriptionDefault
backgroundScriptThe name of your background scriptbackground
contentScriptThe name of your content scriptcontent
reloadPageShould the content script reload their pagetrue

Example

const path = require('path')
const ExtensionReloader = require('../webpack-reload-extension')

module.exports = {
  mode: process.env.NODE_ENV,
  entry: {
    content: './content.js',
    background: './background.js'
  },
  output: {
    path: path.resolve(__dirname, 'dist'),
    filename: '[name].js'
  },
  plugins: [
    new ExtensionReloader({
      backgroundScript: 'background',
      contentScript: 'content',
      reloadPage: true
    })
  ]
}
0.0.6

6 years ago

0.0.5

6 years ago

0.0.4

6 years ago

0.0.3

6 years ago

0.0.2

6 years ago

0.0.1

6 years ago