Express Brunch with Jade
CoffeeScript JavaScript Shell
Switch branches/tags
Nothing to show

#Express Brunch with Jade

Express Brunch with Jade is a Brunch app skeleton that has everything hipsters has, but adds a custom Express Server, public & server file watcher, built-in reload, custom Backbone model/view/collection helpers, Jade client & server side templates and over 70 mocha BDD tests.

Express Brunch with Jade's custom file watches any files you specify, server and/or public static file compiled by brunch, reloads the Express App and sends a reload command to the client when it detects a change.

Files & Directories that are watched and ignored are configured under the server section in the


        path: ''
        port: 3333
        base: '/'
        app: 'express'
        debug: 'brunch:server'
        persistent: true
        interval: 100
        watched: ['public', 'express']
        ignore: /(^[.#]|(?:~)$)/
        source: /.*\.coffee$/
            enabled: on
                pattern: /.*\.coffee$/
                        value: 4
                        level: "error"
            enabled: on
                pattern: /^.*_test\.coffee$/

Cordell Walker - CI Ranger

The server walk and watch functionality has been made into its own module called Cordell.



Testing Framework

Code Coverage Framework

Getting started

brunch new <appname> --skeleton git://
cd <appname>
brunch w -s


$ git clone git://
$ cd ExpressBrunchJade
$ npm install
$ brunch w -s


$ git clone git:// && cd ExpressBrunchJade && npm install && brunch w -s

Optimization Plugins

The traditional uglify-brunch plugin has been replaced with ugly-blanket-brunch, which creates separate cov.js and min.js files.

Optimization must be enabled when starting brunch

$ brunch w -s -o


The brunch test command is pretty much broke. It uses jsdom, which has many issues... Plans are in the works for brunch to use phantomjs in the future. Until then, there are better ways to run tests:

Mocha in the browser, Just open your browser to http://localhost:3333/test/ after running:

brunch w -s -o

Note: Doesn't work in IE. Some tests fail with global leak detected in firefox if firebug isn't on...


npm install -g mocha-phantomjs
mocha-phantomjs public/test/index.html

Note: Windows phantomjs support is sketchy (path issues)

Karma!!! (Formally Testacular) Best approach, multiple browser tests (including phantomjs)...

npm install -g karma
karma start --browsers Chrome,ChromeCanary,Firefox,PhantomJS

Note: On Windows x64, use karma.x64_ENV.bat to help with browser paths


Brunch debug events can be monitored by setting the DEBUG=brunch:* environment variable.