Created
March 25, 2017 19:38
-
-
Save dimart/37ae7164c31e1e35126dc9ff801aa62f to your computer and use it in GitHub Desktop.
Monaco
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/build.sbt b/build.sbt | |
index 0af6612..90f2908 100644 | |
--- a/build.sbt | |
+++ b/build.sbt | |
@@ -188,7 +188,7 @@ lazy val scastie = project | |
balancer, | |
instrumentation, | |
sbtRunner, | |
- codemirror, | |
+ monaco, | |
client, | |
runtimeDotty, | |
sbtScastie, | |
@@ -234,6 +234,23 @@ lazy val codemirror = project | |
) | |
.enablePlugins(ScalaJSPlugin) | |
+/* monaco is a facade to the the Monaco Editor, javascript editor that powers VS Code */ | |
+lazy val monaco = project | |
+ .settings(baseSettings) | |
+ .settings( | |
+ jsDependencies ++= { | |
+ def monacoD(path: String): JSModuleID = | |
+ "org.webjars.npm" % "monaco-editor" % "0.8.3" % "compile" / s"$path.js" minified s"$path.js" | |
+ | |
+ List( | |
+ monacoD("min/vs/loader"), | |
+ monacoD("min/vs/editor/editor.main").dependsOn("min/vs/loader.js").dependsOn("react-dom-server.js") | |
+ ) | |
+ }, | |
+ libraryDependencies += "org.scala-js" %%% "scalajs-dom" % scalajsDomVersion | |
+ ) | |
+ .enablePlugins(ScalaJSPlugin) | |
+ | |
def react(artifact: String, | |
name: String, | |
configuration: Configuration = Compile): JSModuleID = | |
@@ -276,7 +293,7 @@ lazy val client = project | |
jsEnv in Test := new PhantomJS2Env(scalaJSPhantomJSClassLoader.value) | |
) | |
.enablePlugins(ScalaJSPlugin, SbtWeb) | |
- .dependsOn(codemirror, api211JS) | |
+ .dependsOn(monaco, api211JS) | |
lazy val instrumentation = project | |
.settings(baseSettings) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment