uglify-js-export
TypeScript icon, indicating that this package has built-in type declarations

3.17.4 • Public • Published

uglify-js-export

npm version npm version npm year jsDelivr hits (npm)(year) CI

UglifyJS is a JavaScript parser, minifier, compressor and beautifier toolkit.

A transform to make UglifyJS work in CommonJS.

Installation

npm i uglify-js-export

Usage

import UglifyJS from 'uglify-js-export';

const code = "function add(first, second) { return first + second; }";
const result = UglifyJS.minify(code);

console.log(result.error); // runtime error, or `undefined` if no error
console.log(result.code);  // minified output: function add(n,d){return n+d}

License

Licensed under the MIT License.

Readme

Keywords

Package Sidebar

Install

npm i uglify-js-export

Weekly Downloads

879

Version

3.17.4

License

MIT

Unpacked Size

1.02 MB

Total Files

4

Last publish

Collaborators

  • wcjiang