Description
Vegetto is a module for allowing divided nodejs development, so that this module groups and files minify.
npm install vegetto
Minify and merge files: .js, .json, .css and .html
Usage
config.json
{
"files": {
"./folder/file.min.js": [
"./folder/dev/file1.js",
"./folder/dev/file2.js"
]
},
"options": {}
}
vegetto config.json
Vegetto heard and modified files will be saved in time so minify file.min.js
Refresh
Adding "refresh" the object attribute options can create a list of files you hear the change of the final file, so that when this is changed it will be stored in those files.
{
"files": {
"./folder/file.min.js": [
"./folder/dev/file1.js",
"./folder/dev/file2.js"
]
},
"options": {
"refresh": {
"./folder/file.min.js": [
"./olderFolder/file.js"
]
}
}
}
Minify project
Parse the script tags, link and style, read the files and then compressed to minify, so that the project remains minified html.
{
"project": {
"./dist": "./dev/app.html"
}
}