Managing Dependencies in sbt

Dependencies in sbt are added to build.sbt using the following format:

libraryDependencies += "org.typelevel" %% "cats-core" % "2.9.0"

Use %% for Scala version-specific artifacts. You can also add multiple dependencies:

libraryDependencies ++= Seq(
  "com.typesafe.akka" %% "akka-actor" % "2.6.20",
  "org.scalatest" %% "scalatest" % "3.2.15" % Test
)

sbt will download and cache them automatically.

← PrevNext →