-
Notifications
You must be signed in to change notification settings - Fork 33
Description
Possible approach: because scala-js can only compile to one js file (along with a dependency js file), I think the content script and popup window should be different sbt projects - bringing the total to three.
The content script and popup projects can be normal scala-js projects and only require the ScalaJSPlugin.
In the scala-js-chrome project, the build.sbt will specify the the two other projects. The ChromeSbtPlugin will compile the content and popup projects and move their outputted js files to the correct build directory. The manifest.json will have to be modified as well.
I made a poc of creating three different projects and manually copying over the necessary files with an ugly shell script https://github.com/kramer425/scala-js-chrome-extension-example