From ecb9fdd0719bd0087e3fe4f7e4a4717e93117d27 Mon Sep 17 00:00:00 2001 From: Li Haoyi Date: Sat, 15 Feb 2014 10:33:30 -0800 Subject: fixed some stuff --- readme.md | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'readme.md') diff --git a/readme.md b/readme.md index e428f38..9cf6408 100644 --- a/readme.md +++ b/readme.md @@ -19,9 +19,13 @@ To Use - Modify the `packageJS` task with the following setting, to make it generate the snippet of `workbench.js` file needed to communicate with SBT: ```scala +import scala.js.workbench.Plugin._ + +buildSettingsX + packageJS in Compile := { - (packageJS in Compile).value :+ scala.js.workbench.generateClient.value - } + (packageJS in Compile).value :+ scala.js.workbench.generateClient.value +} ``` - Define your `bootSnippet`, which is a piece of javascript to be run to start your application, e.g. `bootSnippet := "ScalaJS.modules.example_ScalaJSExample().main();"`. scala-js-workbench requires this so it can use it to re-start your application later on its own. You do not also need to include this on the page itself, as scala-js-workbench will execute this snippet when the browser first connects. -- cgit v1.2.3