Organizational Research By

Surprising Reserch Topic

stylus and express stylesheets are not re compiled when modified


stylus and express stylesheets are not re compiled when modified  using -'node.js,express,stylus'

I am running latest version of Node on Mac OS X. I've installed Express together with Stylus. Also the latest versions.



Stylus is not re-compiling my .styl files, when I modify them. How can I fix this?



The only solution to getting my .styl files re-compiled, is to delete the compiled .css files... re-starting my application, or doing a clear-cache-refresh (CMD + Shift + R) is not resulting a re-compile.

Here's a dump of my application configuration. It's basically the same as when you create a new express application with the executable...

app.configure(function ()
{
    this.set("views", __dirname + "/views");
    this.set("view engine", "jade");

    this.use(express.bodyParser());
    this.use(express.methodOverride());
    this.use(express.static(__dirname + '/public'));

    this.use(require("stylus").middleware({
        src: __dirname + "/public",
        compress: true
    }));

    this.use(this.router);
});


Both my .styl and the compiled .css files are located in [application]\public\stylesheets\
    
asked Sep 18, 2015 by tejas lakhani
0 votes
4 views



Related Hot Questions



Government Jobs Opening


...