Last active
June 10, 2016 04:05
-
-
Save i5on9i/c2ddc1771f5174405c9200fa7f5491ea to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//------------------------------------------------ | |
// | |
// Gruntfile.js | |
// | |
//------------------------------------------------ | |
require('load-grunt-tasks')(grunt); | |
grunt.initConfig({ | |
pkg: grunt.file.readJSON('package.json'), | |
// Setup tasks | |
bower_concat: require('./tasks/bower-concat')(paths), | |
}) | |
//------------------------------------------------ | |
// | |
// bower-concat.js | |
// | |
//------------------------------------------------ | |
// @ref : https://github.com/sapegin/grunt-bower-concat | |
module.exports = function (paths) { | |
//'use strict'; | |
// if the specification is written in bower.json, you don't have to write it here again. | |
return { | |
all: { | |
dest: 'build/lib/_bower.js', | |
// cssDest: 'build/_bower.css', | |
exclude: [ | |
'jquery', | |
'fontawesome', | |
'react', | |
], | |
dependencies: { // order | |
'underscore': ['jquery'], // underscore needs jquery, | |
'jquery-toast-plugin': ['jquery'], // toast-plugin needs jquery, | |
}, | |
bowerOptions: { | |
relative: false | |
}, | |
mainFiles: { // without this, bower-concat use the files in "bower.json main" | |
'jquery-prettyPhoto': 'js/jquery.prettyPhoto.js', | |
'owlcarousel': [ | |
'owl-carousel/owl.transitions.css', | |
'owl-carousel/owl.carousel.css', | |
'owl-carousel/owl.carousel.js', | |
], | |
'datatables': [ | |
"media/js/jquery.dataTables.js", | |
"media/js/dataTables.bootstrap.js" | |
] | |
} | |
} | |
}; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment