wilson428 / node-lessify

LESS precompiler plugin for Browserify v2
MIT License
24 stars 13 forks source link

Possibility for CSS to be bundled into a separate CSS file #13

Closed mischkl closed 9 years ago

mischkl commented 9 years ago

We would like the ability to keep the CSS file separate from the JavaScript file instead of having it be embedded, so that it can then be linked within the HTML instead of being injected as an internal style. Kind of similar to https://github.com/capaj/require-stylify except that the result should be one CSS file instead of many. And since the require-stylify project seems not to be maintained anymore this seems like the place to request this feature. :)

Of course it is possible to achieve something similar via a build script but the point is that we want the benefit of requiring our CSS in JavaScript modules, so that if a JS module isn't used its CSS is automatically excluded as well.

mischkl commented 9 years ago

On second thought this ought to be possible using a combination of parcelify and less-css-stream... so I am closing the issue after all.

madhums commented 8 years ago

@mischkl could you share an example of how you got it to work?

wilson428 commented 8 years ago

It sounds to me like this is a perfect job for grunt, since the whole point of this mod is to bake the CSS into the JS.