Skip to content
This repository has been archived by the owner on Jul 24, 2024. It is now read-only.

Force option does not work in middleware #173

Closed
ghinda opened this issue Oct 21, 2013 · 2 comments
Closed

Force option does not work in middleware #173

ghinda opened this issue Oct 21, 2013 · 2 comments

Comments

@ghinda
Copy link

ghinda commented Oct 21, 2013

I'm using the middleware with express like this:

app.use(
    sass.middleware({
        force: true,
        src: config.root + '/public',
        outputStyle: 'compressed'
    })
);

But, if the main.css file has already been compiled, or it already exists, it does not compile the scss file.

@nowk
Copy link

nowk commented Nov 2, 2013

Your static middleware call app.use(express.static(__dirname + '/public')); needs to come after your call to the sass middleware. Else the static middleware picks up requests to public and they never reach sass. Assuming you set it up that way.

@deanmao
Copy link
Contributor

deanmao commented Jan 3, 2014

I manually checked this issue, and it seems to be fine. Perhaps @nowk guessed correctly at your problem?

@deanmao deanmao closed this as completed Jan 3, 2014
jiongle1 pushed a commit to scantist-ossops-m2/node-sass that referenced this issue Apr 7, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants