-
-
Notifications
You must be signed in to change notification settings - Fork 57
/
Copy pathbuild.sbt
45 lines (39 loc) · 1.61 KB
/
build.sbt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
enablePlugins(ScalaJSPlugin)
enablePlugins(JSDependenciesPlugin)
name := "slinky-scalajsreact-interop"
libraryDependencies ++= {
CrossVersion.partialVersion(scalaVersion.value) match {
case Some((2, _)) =>
Seq(
"com.github.japgolly.scalajs-react" %%% "core" % "1.7.7"
)
case _ =>
Seq(
"com.github.japgolly.scalajs-react" %%% "core" % "2.0.0"
)
}
}
libraryDependencies += "org.scalatest" %%% "scalatest" % "3.2.18" % Test
Test / jsEnv := new org.scalajs.jsenv.jsdomnodejs.JSDOMNodeJSEnv()
Test / unmanagedResourceDirectories += baseDirectory.value / "node_modules"
jsDependencies ++= Seq(
((ProvidedJS / "text-enc/lib/encoding.js")
.minified("text-enc/lib/encoding.js")
.commonJSName("TextEnc")) % Test,
((ProvidedJS / "react/umd/react.development.js")
.minified("react/umd/react.production.min.js")
.dependsOn("text-enc/lib/encoding.js")
.commonJSName("React")) % Test,
((ProvidedJS / "react-dom/umd/react-dom.development.js")
.minified("react-dom/umd/react-dom.production.min.js")
.dependsOn("react/umd/react.development.js")
.commonJSName("ReactDOM")) % Test,
((ProvidedJS / "react-dom/umd/react-dom-test-utils.development.js")
.minified("react-dom/umd/react-dom-test-utils.production.min.js")
.dependsOn("react-dom/umd/react-dom.development.js")
.commonJSName("ReactTestUtils")) % Test,
((ProvidedJS / "react-dom/umd/react-dom-server.browser.development.js")
.minified("react-dom/umd/react-dom-server.browser.production.min.js")
.dependsOn("react-dom/umd/react-dom.development.js")
.commonJSName("ReactDOMServer")) % Test
)