Last active
December 15, 2015 00:59
-
-
Save dylants/5176618 to your computer and use it in GitHub Desktop.
less middleware app.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var lessMiddleware = require("less-middleware"); | |
app.use(lessMiddleware({ | |
src: __dirname + "/less", | |
dest: __dirname + "/public/css", | |
// if you're using a different src/dest directory, you | |
// MUST include the prefex, which matches the dest | |
// public directory | |
prefix: "/css", | |
// force true recompiles on every request... not the | |
// best for production, but fine in debug while working | |
// through changes | |
force: true | |
})); | |
app.use(express.static(__dirname + "/public")); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment