Concatenate @import
CSS references into a single stylesheet.
import (
"github.com/ef2k/stylecat"
)
func main() {
src, err := stylecat.Run("/the/path/to/public/css/master.css", nil)
}
When stylesheets link to absolute paths e.g: /css/master.css
, set a RootPath
:
src, err := stylecat.Run("/the/path/to/public/css/master.css", &stylecat.Config{
RootPath: "/the/path/to/public"
})
Fixes? Ideas? Improvements? Jump in. All are welcome!
MIT.