Fix parameter for `minifyInPlace` (#5)

This commit is contained in:
Pesche 2020-07-15 01:48:09 +02:00 committed by GitHub
parent 892e10c92e
commit 3a778e6df2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -126,8 +126,8 @@ const cfg = { minifyJs: false };
const minified = minifyHtml.minify("<p> Hello, world! </p>", cfg);
// Alternatively, minify in place to avoid copying.
const source = Buffer.from("<p> Hello, world! </p>", cfg);
minifyHtml.minifyInPlace(source);
const source = Buffer.from("<p> Hello, world! </p>");
minifyHtml.minifyInPlace(source, cfg);
```
minify-html is also available for TypeScript: