Skip to content

Commit

Permalink
Add http4s dep to scastie
Browse files Browse the repository at this point in the history
  • Loading branch information
armanbilge committed Nov 21, 2021
1 parent a549c96 commit e846ef3
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion site/docs/index.md
Expand Up @@ -45,7 +45,13 @@ def clearOutput: IO[Unit] =
IO(document.getElementsByClassName("scastie")(0).asInstanceOf[js.UndefOr[Element]].foreach(_.remove()))

def setOutput(code: String): IO[Unit] = IO {
js.Dynamic.global.scastie.Embedded("#output", js.Dynamic.literal(code = code))
js.Dynamic.global.scastie.Embedded(
"#output",
js.Dynamic.literal(
code = code,
sbtConfig = """libraryDependencies += "org.http4s" %% "http4s-core" % "0.23.6""""
)
)
}

def run = clearOutput >> handleErrors(process.flatMap(setOutput))
Expand Down

0 comments on commit e846ef3

Please sign in to comment.