Use bower with heroku

Hello!

Bower is pretty awsome! Heroku too!

Use them together!

Without creating your own Heroku buildpack, you can achieve that quite easily.

Just add a dependency to Bower in your package.json and then rely on the npm scripts to execute a postinstall command (https://npmjs.org/doc/scripts.html).

So you'll end up with somthing like this in your package.json:

"dependencies": {
    "bower": "0.6.x"
},
"scripts": {
    "postinstall": "./node_modules/bower/bin/bower install"
}

And that's it! Heroku will run a npm install that will execute the bower install.

Pros: one command to rule them all.

Cons: you unnecessarily embed bower as a dependency.