-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathGruntfile.js
38 lines (36 loc) · 864 Bytes
/
Gruntfile.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
module.exports = function (grunt) {
grunt.initConfig({
browserify: {
options: {
transform: [ require('grunt-react').browserify ],
browserifyOptions:{
debug: true
}
},
app: {
src : 'src/js/app.js',
dest: 'js/app.js'
}
},
stylus : {
dev:{
options:{
linenos : true
},
files : {
'./css/app.css' : './src/stylus/index.styl'
}
}
},
watch: {
files: ['./src/**/*'],
tasks: ['build']
},
})
grunt.loadNpmTasks('grunt-browserify');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-contrib-stylus');
grunt.registerTask('default', ['build', 'watch']);
grunt.registerTask('build', ['browserify:app', 'stylus']);
//grunt.registerTask('serve', ['connect:server']);
};