@bytehide/rollup-shield
TypeScript icon, indicating that this package has built-in type declarations

1.1.0 • Public • Published

@bytehide/rollup-shield

A Rollup plugin for obfuscating JavaScript code using ByteHide Shield.

Installation

npm install @bytehide/rollup-shield --save-dev

Usage

// rollup.config.js
import ByteHideShieldPlugin from '@bytehide/rollup-shield';

export default {
  input: 'src/index.js',
  output: {
    dir: 'dist',
    format: 'es'
  },
  plugins: [
    ByteHideShieldPlugin({
      projectToken: 'your-bytehide-token',
      // Optional configurations
      distDir: 'dist',
      replace: false,
      obfuscatedExtension: '.obf',
      exclude: ['excluded.js'],
      config: {
        controlFlowFlattening: true,
        debugProtection: false,
        devtoolsBlocking: false,
      }
    })
  ]
};

Options

  • projectToken (required): Your ByteHide project token
  • distDir (optional): Output directory (default: 'dist')
  • replace (optional): Replace original files (default: false)
  • obfuscatedExtension (optional): Extension for obfuscated files (default: '.obf')
  • exclude (optional): Array of files to exclude from obfuscation
  • config (optional): ByteHide Shield configuration options

License

MIT


Happy coding but keep it safe with @bytehide/rollup-shield! 🛡️

Package Sidebar

Install

npm i @bytehide/rollup-shield

Weekly Downloads

128

Version

1.1.0

License

ISC

Unpacked Size

9.15 kB

Total Files

4

Last publish

Collaborators

  • jespanag
  • vytehide
  • kikebytehide