Integrant methods for compiling Garden files to CSS in the Duct framework.
To install, add the following to your project :dependencies
:
[compiler.garden "0.1.3"]
The library provides the :duct.compiler/garden
key, and is used to compile Garden styles in namespaces to CSS in development and production environments.
:duct.compiler/garden
{:builds [{:id "main"
:stylesheet example.style/screen
:compiler {:output-to "target/resources/example/public/css/style.css"
:pretty-print? false}}]}
The :builds
option is mandatory. :stylesheet
is a var contain the garden stylesheet datastructure. The [:compiler :output-to]
option is where the garden compiler output the CSS file to. You can have multi CSS files compiled, just by defining more build. the :compiler
will pass to garden compiler directly, you can get more detail about configuration from Garden
In order to get auto css refresh in development mode, the css must be either output to the duct default css path resources/baywatch/public/css
or define the css path explicitly in dev.edn
.
:duct.server/figwheel
{:css-dirs ["target/resources/example/public/css" "resources/example/public/css"]
:builds [...]}
Distributed under the Eclipse Public License either version 1.0 or (at your option) any later version.