Scala JS: Set Target Folder for JavaScript Build
Recently I've been interested in Scala JS. It would be great to share logic on client and server side and to write all code in Scala. But SBT can be a bit tricky and my project setup was divided into two:- One webapp with a Java web container
- Scala JS with logic shared between frontend and backend
To get SBT to build the JavaScript from my Scala JS project to my webapp I needed to add the following lines in my root build.sbt file:
val jsDir = "../gae/src/main/webapp"
crossTarget in (Compile, fastOptJS) := file(jsDir)
Project combining Scala JS and Java web container
You can check out my project which uses this build at
Inga kommentarer:
Skicka en kommentar