scala - How to serve files generated by sbt-js using spray-can -


this basic thing, can't work. spray-template project have added sbt-js plugin.

when run js command finds , processes js files in src/main/[resources]/web/js/ , places them in target/scala-2.11/resource_managed/[main]/resources/web/js/

(the [ ] marks directories shows resource directories in intellij).

i try serve js files this, works unprocessed file:

trait jscontent extends httpservice {   val jsroute = path("js1") {     getfromresource("web/js/test.js") // unprocessed js file loads fine.   } ~ path("js2") {     getfromresource("resources/web/js/test.js") // how locate generated file?   } } 

the directory containing processed files listed when doing show resourcedirectories in sbt console, not included in jar produced when running package.

so how point out sbt want use managed js resources?


Comments

Popular posts from this blog

ruby on rails - RuntimeError: Circular dependency detected while autoloading constant - ActiveAdmin.register Role -

c++ - OpenMP unpredictable overhead -

javascript - Wordpress slider, not displayed 100% width -