billymoon / Stylus

Stylus Package for Sublime Text 2 / 3
Other
129 stars 31 forks source link

Stylus not compressing CSS in Sublime Text 3 #46

Closed DJviolin closed 9 years ago

DJviolin commented 9 years ago

I leaved this in the Stylus User Settings file:

{
    "compress": true
}

But when I building my CSS, nothing changes. I still got uncompressed CSS code, where everything is in multiline, instead of one line:

p {
  margin: 10px;
  padding: 5px;
}
grassator commented 9 years ago

This feature was user-contributed (i.e. unsupported), but as far as I understand compress: true only works with compileOnSave: true option.

If you want to compress on manual build you have to use special Build: compress command.

But in general my advice would be to use a proper build system like gulp, grunt or even simple npm tasks.