You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

50 lines
1.6 KiB

4 years ago
  1. enablePlugins(ScalaJSPlugin)
  2. enablePlugins(ScalaJSBundlerPlugin)
  3. enablePlugins(ScalablyTypedConverterPlugin)
  4. enablePlugins(ShoconPlugin)
  5. // enablePlugins(SbtTwirl)
  6. name := "scalajs-standalone"
  7. scalaVersion := "2.13.2"
  8. // This is an application with a main method
  9. scalaJSUseMainModuleInitializer := true
  10. // mainClass in Compile := Some("Index.scala")
  11. scalacOptions ++= ScalacOptions.flags
  12. libraryDependencies ++= Seq(
  13. "org.scala-js" %%% "scalajs-dom" % "1.0.0",
  14. "com.github.japgolly.scalajs-react" %%% "core" % "1.7.0",
  15. "com.github.japgolly.scalajs-react" %%% "extra" % "1.7.0",
  16. "com.github.japgolly.scalajs-react" %%% "ext-monocle-cats" % "1.7.0",
  17. "com.softwaremill.quicklens" %%% "quicklens" % "1.5.0",
  18. "com.github.julien-truffaut" %%% "monocle-core" % "2.0.4",
  19. "com.github.julien-truffaut" %%% "monocle-macro" % "2.0.4",
  20. "org.typelevel" %%% "cats-core" % "2.1.1",
  21. "org.typelevel" %%% "cats-core" % "2.1.1",
  22. "org.typelevel" %%% "cats-effect" % "2.1.4",
  23. "io.monix" %%% "monix" % "3.2.2",
  24. // "com.github.japgolly.scalajs-react" %%% "test" % "1.7.0",
  25. "org.akka-js" %%% "shocon" % "1.0.0",
  26. "com.typesafe.play" %%% "play-json" % "2.9.0"
  27. )
  28. useYarn := true
  29. stFlavour := Flavour.Japgolly
  30. Compile / npmDependencies ++= Seq(
  31. "react" -> "16.13.1",
  32. "react-dom" -> "16.13.1",
  33. "@types/react" -> "16.9.34",
  34. "@types/react-dom" -> "16.9.6"
  35. )
  36. compile in Compile := (compile in Compile).dependsOn(shoconConcat).value
  37. webpackDevServerExtraArgs in fastOptJS ++= Seq(
  38. "--content-base",
  39. (baseDirectory in ThisBuild).value.getAbsolutePath
  40. )
  41. webpackDevServerExtraArgs := Seq("--inline")
  42. webpackBundlingMode := BundlingMode.LibraryOnly()