Experimental Plugin to create module by merging files using a module declaration file
This plugin requires Grunt.
If you haven't used Grunt before, be sure to check out the Getting Started guide, as it explains how to create a Gruntfile as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:
npm install grunt-module-merge --save-dev
Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:
grunt.loadNpmTasks('grunt-module-merge');
In your project's Gruntfile, add a section named module_merge
to the data object passed into grunt.initConfig()
.
grunt.initConfig({
module_merge: {
files {
src : ['dir/**/*.json'],
dest : 'build_dir/scripts/'
},
},
},
})
Sample of module definition
{
"name" : "module",
"files" : ["somefile.js", "other.js", "*.js]
}
The base path is the path where is the module definition file. We support also the integration of angular template in the module
Example :
{
"name" : "module",
"files" : ["somefile.js", "other.js", "*.js", "*.tpl.html"]
}
0.1.6
Copyright (c) 2014 jalalc. Licensed under the MIT license.