scala - scalatra not displaying views that match routes correctly -
i'm getting started scalatra , jade, views match route come
wrapped in <pre></pre>
tags.
project setup so:
//scalatraservlet.scala def get("/index") { jade("index") } //web-inf/templates/views/index.jade h1 indexing. //web-inf/templates/views/no_route.jade h1 works correctly!
if hit localhost:8080/index
on browser, shows whole html structure inside <pre></pre>
tags, if hit localhost:8080/test
, doesn't have route defined in scalatra, renders correctly. doing wrong? there caveat working routes , jade?
have tried adding contenttype before calling jade(...) ?
def get("/index") { contenttype="text/html" jade("index") }
Comments
Post a Comment