/sbt-inline-css

sbt-web plugin for the juice css inliner

Primary LanguageScalaApache License 2.0Apache-2.0

Note that this plugin is presently only working with an engineType set to Node e.g.: set JsEngineKeys.engineType := JsEngineKeys.EngineType.Node

sbt-inline-css

sbt-web plugin for inlining css in html files.

Uses the juice node plugin

How to use

This plugin requires Node to be installed and the 'juice' package to be available at runtime. To install juice with npm:

npm install juice

In your build file add an include filter for the files you want to inline:

includeFilter in (Assets, InlineCssKeys.inlineCss) := "test.html"

This will generate files where 'inline.' is added to the file extension; e.g. 'test.inline.html' will be generated for a file named 'test.html'.