Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Use new patched grunt-browserify for building client side JavaScript

  • Loading branch information...
commit 4985cb0858d4a614cb29cd8b2b56308580299727 1 parent 8e88dcf
@jacobrask authored
Showing with 19 additions and 15 deletions.
  1. +19 −15 grunt.js
View
34 grunt.js
@@ -5,39 +5,43 @@ module.exports = function(grunt) {
// Project configuration.
grunt.initConfig({
pkg: '<json:package.json>',
- min: {
- dist: {
- src: [ 'dist/docs.js' ],
- dest: 'dist/docs.js'
- }
- },
browserify: {
+ 'dist/docs.js': {
+ entries: [ 'web/app.js' ],
+ aliases: [ 'jquery:jquery-browserify' ]
+ },
'test/lib/views.js': {
entries: [ 'test/navigation.js', 'test/previews.js' ]
}
},
+ jade: {
+ html: {
+ src: [ 'web/index.jade' ],
+ dest: 'dist/index.html',
+ options: { client: false, pretty: true }
+ }
+ },
concat: {
dist: {
src: [ 'web/*.css', 'web/views/*.css' ],
dest: 'dist/docs.css'
}
},
+ min: {
+ dist: {
+ src: [ 'dist/docs.js' ],
+ dest: 'dist/docs.js'
+ }
+ },
mincss: {
dist: {
files: { 'dist/docs.css': [ '<config:concat.dist.src>' ]
}
}
},
- jade: {
- html: {
- src: [ 'web/index.jade' ],
- dest: 'dist/index.html',
- options: { client: false, pretty: true }
- }
- },
watch: {
files: [ 'web/**', 'grunt.js' ],
- tasks: 'jade concat'
+ tasks: 'browserify concat'
},
jshint: {
options: {
@@ -59,7 +63,7 @@ module.exports = function(grunt) {
// Default task.
grunt.registerTask('default', 'jade browserify:dist/docs.js min mincss');
- grunt.registerTask('dev', 'concat');
+ grunt.registerTask('dev', 'concat browserify:dist/docs.js');
grunt.registerTask('test', 'browserify:test/lib/tests.js buster');
grunt.loadNpmTasks("grunt-contrib");

0 comments on commit 4985cb0

Please sign in to comment.
Something went wrong with that request. Please try again.