You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
48 lines
988 B
48 lines
988 B
'use strict';
|
|
|
|
module.exports = function(grunt) {
|
|
|
|
//Load NPM tasks
|
|
grunt.loadNpmTasks('grunt-browserify');
|
|
grunt.loadNpmTasks('grunt-contrib-watch');
|
|
grunt.loadNpmTasks('grunt-mocha-test');
|
|
|
|
// Project Configuration
|
|
grunt.initConfig({
|
|
browserify: {
|
|
client: {
|
|
src: ['bitcore.js'],
|
|
dest: 'browser/bundle.js',
|
|
options: {
|
|
debug: true,
|
|
alias: ['browserify-bignum/bignumber.js:bignum'],
|
|
standalone: 'bitcore',
|
|
}
|
|
},
|
|
vendor: {
|
|
src: ['browser/vendor_load.js'],
|
|
dest: 'browser/vendor.js',
|
|
options: {
|
|
|
|
}
|
|
}
|
|
},
|
|
watch: {
|
|
scripts: {
|
|
files: ['**/*.js', '**/*.html', '!**/node_modules/**', '!**/bundle.js', '!**/vendor.js'],
|
|
tasks: ['browserify'/*, 'mochaTest'*/],
|
|
},
|
|
},
|
|
mochaTest: {
|
|
options: {
|
|
reporter: 'spec',
|
|
},
|
|
src: ['test/*.js'],
|
|
},
|
|
|
|
});
|
|
|
|
grunt.registerTask('default', ['watch']);
|
|
|
|
};
|
|
|
|
|