string-minify
Version:
Simple string (file-content) minifier. This helper removes all extra whitespaces, tabs, newlines and trims the string.
30 lines (18 loc) • 798 B
Markdown
> Simple string (file-content) minifier. This helper removes all extra whitespaces, tabs, newlines and trims the string. Please, do not blame me for this one-line module 😉
## Install
```
$ npm install --save string-minify
```
## Usage
```js
const minifier = require('string-minify');
const testString = `Hello world!
I am a string! `;
const idealString = 'Hello world! I am a string!';
console.log(minifier(string) === idealString); // => true
```
- [grunt-file-minify](https://github.com/soul-wish/grunt-file-minify) - Grunt plugin for simple file minification
MIT © [Sergey Lysenko](http://soulwish.info)