1.0.1 • Published 5 years ago

bookmarklet-wrapper-webpack-plugin v1.0.1

Weekly downloads
38
License
MIT
Repository
github
Last release
5 years ago

Bookmarklet Wrapper Webpack Plugin

Wraps output file in IIFE and adds 'javascript:' prefix:

javascript: (function() {
  // ... file content
})();

Works only in production mode.

Installation

npm install --save-dev bookmarklet-wrapper-webpack-plugin

Usage

const BookmarkletWrapperPlugin = require('bookmarklet-wrapper-webpack-plugin');

module.exports = {
  // ...

  plugins: [new BookmarkletWrapperPlugin()]
};