rollup-plugin-strip

Remove debugger statements and functions like assert.equal and console.log from your code.

This package has been deprecated and is no longer maintained. Please use @rollup/plugin-strip
Last updated 3 years ago .
· Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install rollup-plugin-strip 
SYNC missed versions from official npm registry.

rollup-plugin-strip

Remove debugger statements and functions like assert.equal and console.log from your code.

Installation

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

Usage

// rollup.config.js
import strip from 'rollup-plugin-strip';

export default {
  input: 'src/index.js',
  output: [
    {
      format: 'cjs',
      file: 'dist/my-lib.js'
    }
  ],
  plugins: [
    strip({
      // set this to `false` if you don't want to
      // remove debugger statements
      debugger: true,

      // defaults to `[ 'console.*', 'assert.*' ]`
      functions: [ 'console.log', 'assert.*', 'debug', 'alert' ],

      // set this to `false` if you're not using sourcemaps –
      // defaults to `true`
      sourceMap: true
    })
  ]
};

License

MIT

Current Tags

  • 1.2.2                                ...           latest (3 years ago)

8 Versions

  • 1.0.1 [deprecated]           ...           6 years ago
  • 1.0.2 [deprecated]           ...           6 years ago
  • 1.0.3 [deprecated]           ...           6 years ago
  • 1.1.0 [deprecated]           ...           6 years ago
  • 1.1.1 [deprecated]           ...           6 years ago
  • 1.2.0 [deprecated]           ...           4 years ago
  • 1.2.1 [deprecated]           ...           4 years ago
  • 1.2.2 [deprecated]           ...           3 years ago
Dependencies (3)
Dev Dependencies (4)

Copyright © npmmirror.com | 浙ICP备15033595号-63 |