# html-minifier [TOC] ###### tags: `npm` `cli` --- ## Installation ```shell $ sudo npm i -g html-minifier ``` ## Usage ```shell $ html-minifier \ --collapse-whitespace \ -o dist/projectName/index.html \ dist/projectName/index.html ``` | Option | Description | | ------------------------ | ----------------------------------------------------------------------- | | `--collapse-whitespace` | Collapse white space that contributes to text nodes in a document tree. | | `-o`,`--output` `<file>` | Specify output file (if not specified STDOUT will be used for output). | ## Reference - [npm ยป **html-minifier**](https://www.npmjs.com/package/html-minifier)
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up