springweblobby / swl-website

Weblobby site component
10 stars 11 forks source link

Use node-sass instead of vanilla SASS, require() styles #44

Closed db81 closed 9 years ago

db81 commented 9 years ago

Using node-sass means you don't have to install ruby to work on swl, so the barrier to contributing and deploying is lower.

An interesting feature (not unique to node-sass though) is the ability to require() sass files in modules and then have them added to an output css file or injected into js (in what manner?). Investigate how to do the separate output file one, sounds very useful for libswl.

Relevant packages: https://www.npmjs.com/package/require-stylify https://www.npmjs.com/package/parcelify https://www.npmjs.com/package/sassify

Anarchid commented 9 years ago

Oh yes! Down with the Ruby!

db81 commented 9 years ago

Webpack may be worth looking into. It has CSS require() and promises very fast incremental compile times. Grunt + browserify isn't all that slow, but still somewhat annoying.

A problem I found with integrating swl into zk infra is that if you make zk site or zkl depend on zkwl project in VS, it will run grunt compile every single time even if nothing changed in zkwl. But I'm not sure if you can get incremental builds in webpack from VS. Maybe there's a vanilla VS way to make it track changes in js. Maybe it's better, if improper, not to have other projects depend on zkwl. It seems unwise to sink too much time into VS integration, but I want it to at least build out of the box.

db81 commented 9 years ago

7e7f6521