Skip to content

Commit

Permalink
update doc about background fibers in http4s
Browse files Browse the repository at this point in the history
  • Loading branch information
cyz1901 committed Dec 23, 2023
1 parent 2f04641 commit 9c9144e
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions docs/demos/http4s.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ val app: Resource[IO, HtmlDivElement[IO]] = (
case Right(Repo(stars)) => starsResult.set(s"$stars")
case Left(_) => starsResult.set(s"Not found :(")
}
.background // transfer fetch requests to background fibers to avoid blocking page rendering

div(
h3("How many stars?"),
Expand Down

0 comments on commit 9c9144e

Please sign in to comment.