bowerToLocals
A simple middleware to select all Bower main files and saves them into the response.locals Object.
Install
npm install bower-to-locals
How to use
var express = ;var app = ; ;
To see all the current seleced files:
var express = ;var app = ;var bowerToLocals = ;bowerToLocals; ifappenv === 'development' console;
---- start section bower-to-locals ----
bootstrap.less
bootstrap.css
bootstrap.js
bootstrap.eot
bootstrap.svg
bootstrap.ttf
bootstrap.woff
jquery
---- end section ----
In a jade file for example:
script(src=jquery)script(src=bootstrap.js)
Minify
Js
To minify js just call minify after init
var express = ;var app = ;var bowerToLocals = ;bowerToLocals;bowerToLocals;