rollup-plugin-strip-logger

0.4.1 • Public • Published

rollup-plugin-strip-logger

npm Dependencies Build Status Coverage Status JavaScript Standard Style

Strips out references to a logger package.

Warning: This is very much a work in progress. It's likely to be refactored into something more generic.

Installation

npm install --save-dev rollup-plugin-strip-logger

Usage

import stripLogger from 'rollup-plugin-strip-logger'
 
export default {
  entry: 'src/index.js',
  dest: 'dist/my-lib.js',
  plugins: [
    stripLogger({
      variableNames: ['logger'],
      propertyNames: ['_logger'],
      packageNames: ['my-logger']
    })
  ]
}

Options

variableNames

Remove all references to variables by the names in this array.

propertyNames

Remove all references to obj[name] for each name in this array.

packageNames

Remove all imports of packages/modules by the names in this array.

Author

Tim De Pauw

License

MIT

Readme

Keywords

none

Package Sidebar

Install

npm i rollup-plugin-strip-logger

Weekly Downloads

2

Version

0.4.1

License

MIT

Unpacked Size

6.72 kB

Total Files

5

Last publish

Collaborators

  • timdp