I am able to run scalate from my project with Java, but I'm not sure how to go about passing models to my templates. The following works if I don't return a Viewable or have a variable reference in the template. What am I doing wrong pass a model to the template? Do I have to use Viewable or can I just return the Object? - Thanks
// xxx.UserResource
@GET
@Path("name")
public Viewable myname() {
return new Viewable("name", Util.hashmap("name", "joe"));
}
// xxx.UserResource.name.jade
h1
Hi ${name}