{"name":"@putout/minify","version":"5.5.0","keywords":["putout","minify","AST","babel","printer","api","traverse","generate"],"author":{"url":"https://github.com/coderaiser","name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"license":"MIT","_id":"@putout/minify@5.5.0","maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"homepage":"https://github.com/putoutjs/minify#readme","bugs":{"url":"https://github.com/putoutjs/minify/issues"},"dist":{"shasum":"c615281958443fc791f796f35758980b94da2a37","tarball":"http://registry-npm.ywwl.com/@putout/minify/download/@putout/minify-5.5.0.tgz","fileCount":4,"integrity":"sha512-6zq4/vRUdCixoulucuZ+owuyDkOfQ4AGE5XDdwjWMylQvlhT5hvJHpGstu78rwm0k1QeKbCqTNOF66RdNmHgdg==","signatures":[{"sig":"MEYCIQC5vKUsQanwcuP3gbVU6j/EUTxEWqW3aLmmLj9IOViBjgIhAM+L2ING4JKDBTxHvxo8FZY7AhS5J7AHpdZwpkV0ykAa","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":1190557,"size":316088,"noattachment":false,"key":"/@putout/minify/-/@putout/minify-5.5.0.tgz"},"type":"module","engines":{"node":">=20"},"exports":{".":"./bundle/minify.min.js","./dev":"./lib/minify.js"},"gitHead":"786681b22a3e904836d483d0fe6871fb0ec40cd0","scripts":{"lint":"madrun lint","test":"madrun test","build":"madrun build","minify":"madrun minify","report":"madrun report","wisdom":"madrun wisdom","coverage":"madrun coverage","fix:lint":"madrun fix:lint","fresh:lint":"madrun fresh:lint","lint:fresh":"madrun lint:fresh","watch:test":"madrun watch:test","build:stats":"madrun build:stats","coverage:html":"madrun coverage:html"},"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"repository":{"url":"git+https://github.com/putoutjs/minify.git","type":"git"},"_npmVersion":"11.4.2","description":"🐊Putout-based minifier","directories":{},"_nodeVersion":"24.8.0","dependencies":{},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"^10.1.2","rendy":"^4.1.3","eslint":"^9.2.0","madrun":"^11.0.0","minify":"^14.0.0","montag":"^1.0.0","putout":"^40.0.9","rollup":"^4.5.0","nodemon":"^3.0.1","redlint":"^4.0.0","fullstore":"^3.0.0","supertape":"^11.0.3","try-catch":"^3.0.0","mock-require":"^3.0.3","@putout/bundle":"^4.8.0","just-kebab-case":"^4.2.0","just-snake-case":"^3.2.0","@putout/plugin-esm":"^5.0.0","@putout/plugin-new":"^4.0.0","@putout/eslint-flat":"^3.0.0","@rollup/plugin-json":"^6.0.0","@putout/plugin-types":"^8.0.0","@rollup/plugin-alias":"^6.0.0","eslint-plugin-putout":"^28.0.4","@putout/plugin-for-of":"^9.0.0","@putout/plugin-minify":"^11.0.0","@putout/plugin-regexp":"^12.2.2","@putout/plugin-return":"^2.0.0","@putout/plugin-declare":"^6.0.0","@rollup/plugin-replace":"^6.0.1","@putout/plugin-promises":"^18.3.0","@rollup/plugin-commonjs":"^29.0.0","@putout/plugin-conditions":"^8.1.0","rollup-plugin-bundle-stats":"^4.21.6","@putout/plugin-remove-empty":"^15.0.0","@rollup/plugin-node-resolve":"^16.0.0","rollup-plugin-polyfill-node":"^0.13.0","rollup-plugin-node-externals":"^8.0.0","@putout/plugin-remove-console":"^6.0.0","@putout/plugin-remove-debugger":"^7.0.0","@putout/plugin-simplify-ternary":"^8.0.0","@putout/plugin-logical-expressions":"^8.0.0","@putout/plugin-remove-useless-else":"^2.0.0","@putout/plugin-remove-nested-blocks":"^9.0.0","@putout/plugin-reuse-duplicate-init":"^8.0.0","@putout/plugin-remove-useless-spread":"^13.0.0","@putout/plugin-apply-optional-chaining":"^6.0.0","@putout/plugin-apply-template-literals":"^4.2.0","@putout/plugin-remove-unreachable-code":"^3.0.0","@putout/plugin-remove-unused-variables":"^14.1.0","@putout/plugin-remove-useless-arguments":"^12.0.0","@putout/plugin-remove-useless-variables":"^14.0.0","@putout/plugin-convert-arguments-to-rest":"^4.0.0","@putout/plugin-convert-to-arrow-function":"^4.0.0","@putout/plugin-merge-duplicate-functions":"^4.0.0","@putout/plugin-remove-unused-expressions":"^12.0.0","@putout/plugin-apply-shorthand-properties":"^6.1.0","@putout/plugin-remove-unreferenced-variables":"^6.0.0","@putout/plugin-merge-destructuring-properties":"^12.3.0"},"_npmOperationalInternal":{"tmp":"tmp/minify_5.5.0_1762338083635_0.3845445430357246","host":"s3://npm-registry-packages-npm-production"},"readme":"# @putout/minify [![NPM version][NPMIMGURL]][NPMURL] [![Coverage Status][CoverageIMGURL]][CoverageURL]\n\n[NPMIMGURL]: https://img.shields.io/npm/v/@putout/minify.svg?style=flat&longCache=true\n[NPMURL]: https://npmjs.org/package/@putout/minify \"npm\"\n[CoverageURL]: https://coveralls.io/github/putoutjs/minify?branch=master\n[CoverageIMGURL]: https://coveralls.io/repos/putoutjs/minify/badge.svg?branch=master&service=github\n\n🐊[**Putout**](https://github.com/coderaiser/putout)-based JavaScript minifier.\n\n## Install\n\n```sh\nnpm i @putout/minify\n```\n\n## Supported minifier transforms\n\nHere is list of supported 🐊**Putout** transformations:\n\n- ✅ [`apply-template-literals`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-apply-template-literals#readme);\n- ✅ [`apply-optional-chaining`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-apply-optional-chaining#readme);\n- ✅ [`conditions`](https://github.com/coderaiser/putout/tree/v29.10.0/packages/plugin-conditions#readme);\n- ✅ [`convert-to-arrow-function`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-convert-to-arrow-functions#readme);\n- ✅ [`arguments`](https://github.com/coderaiser/putout/tree/v41/packages/plugin-argumentst#readme);\n- ✅ [`declare`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-declare#readme);\n- ✅ [`for-of`](https://github.com/coderaiser/putout/tree/v34.0.0/packages/plugin-for-of#readme);\n- ✅ [`logical-expressions`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-logical-expressions#readme);\n- ✅ [`merge-duplicate-functions`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-merge-duplicate-functions#readme);\n- ✅ [`esm/merge-duplicate-imports`](https://github.com/coderaiser/putout/tree/v41.0.0/packages/plugin-esm#merge-duplicate-imports);\n- ✅ [`destructuring`](https://github.com/coderaiser/putout/tree/v41.0.0/packages/plugin-destructuring#readme);\n- ✅ [`minify`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-minify#readme);\n- ✅ [`new`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-new#readme);\n- ✅ [`regexp`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-regexp#readme);\n- ✅ [`reuse-duplicate-init`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-reuse-duplicate-init#readme);\n- ✅ [`remove-empty`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-remove-empty#readme);\n- ✅ [`remove-nested-blocks`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-remove-nested-blocks#readme);\n- ✅ [`remove-unused-expressions`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-remove-unused-expressions#readme);\n- ✅ [`arguments`](https://github.com/coderaiser/putout/tree/v41.0.0/packages/plugin-arguments#readme);\n- ✅ [`remove-useless-else`](https://github.com/coderaiser/putout/tree/master/packages/plugin-remove-useless-else#readme);\n- ✅ [`return/remove-useless`](https://github.com/coderaiser/putout/tree/v41.0.0/packages/plugin-return#remove-useless);\n- ✅ [`remove-useless-spread`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-remove-useless-spread/#readme);\n- ✅ [`variables`](https://github.com/coderaiser/putout/tree/v41.0.0/packages/plugin-variables#readme);\n- ✅ [`remove-console`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-remove-console#readme);\n- ✅ [`remove-debugger`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-remove-debugger#readme);\n- ✅ [`remove-unreachable-code`](https://github.com/coderaiser/putout/tree/v29.0.0/packages/plugin-remove-unreachable-code#readme);\n- ✅ [`simplify-ternary`](https://github.com/coderaiser/putout/tree/v34.0.0/packages/plugin-simplify-ternary#readme);\n- ✅ [`types`](https://github.com/coderaiser/putout/tree/v29.7.1/packages/plugin-types#readme);\n\n## API\n\n```js\nimport {minify} from '@putout/minify';\n\nminify(`\n    const a = 5;\n    const b = 6;\n    \n    fn(a, b);\n`);\n```\n\n```zig\n// returns\nvar a=5,b=6;fn(a,b);\n```\n\n### Options\n\nYou can also pass options to `minify`. Here is list of default options:\n\n```js\n({\n    quotes: `'`,\n    fixCount: 1, // the more fixCount - less output size\n    conditions: false,\n    mangleClassNames: true,\n    mangle: true,\n    mergeVariables: true,\n    removeUnusedVariables: false,\n    removeConsole: false,\n    removeUselessSpread: true,\n    applyTemplateLiterals: true,\n    convertStrictEqualToEqual: false,\n});\n```\n\nAnd usage example:\n\n```js\nimport {minify} from '@putout/minify';\n\nconst source = `\n    const a = 5;\n    const b = 6;\n`;\n\nminify(source, {\n    removeUnusedVariables: false,\n});\n```\n\n### How it's compared to X(your benchmark)?\n\n[Benchmark](https://github.com/putoutjs/minify/tree/master/benchmark)\n\n## License\n\nMIT\n","publish_time":1762338083886,"_cnpm_publish_time":1762338083886,"dist-tags":{"latest":"6.1.3"}}