Find file History
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
..
Failed to load latest commit information.
src
LICENSE.md
README.md
pom.xml

README.md

spark-template-water

Spark templating system using Water template engine.

How to use

import static spark.template.water.WaterTemplateEngine.render;
import static spark.template.water.WaterTemplateEngine.waterEngine;

public class WaterTemplateEngineTest {
    public static void main(String[] args) {
        get("/home", (req, res) -> {
            return render(new HelloPage(), req);
        }, waterEngine());
    }
}

//

public class HelloPage extends Template {
    public HelloPage() { add("water", "Water"); }

    @Override
    protected String getFilePath() { return "hello.water"; }
}