cquiroz/scala-java-time

Implementation of the `java.time` API in scala. Especially useful for scala.js

Scala

130

4,113 commits

updated Sep 1, 2026

See the code

README

Scala Java-Time

build Maven Central Scala.js

This project provides an implementation of the java.time package, a date and time library that was added in Java 8. The implementation is based on the original BSD-licensed reference implementation (before it was contributed to OpenJDK).

Usage

The scala-java-time library is currently available for Scala (JVM, version 8 and later), Scala.js (JavaScript) and Scala Native (LLVM). Scala 2.11, Scala 2.12, Scala 2.13 and Scala 3.0.0 are supported.

To get started with SBT, add one (or both) of these dependencies:

  • libraryDependencies += "io.github.cquiroz" %%% "scala-java-time" % "2.6.0"
  • libraryDependencies += "io.github.cquiroz" %%% "scala-java-time-tzdb" % "2.6.0" (optional)

The second dependency contains all time zones available from IANA Time Zone Database. It can be removed if your code doesn't use timezones. Note that the timezone db is fairly large and due to the characteristics of the API it’s not very ammenable to optimization. This database is published every now and then so it may be old. For current version and more possibilities, pleae see the Time Zone section in the documentation.

Documentation

See the documentation

scala
scalajs
time
timezones

Contributors

(top 30 of 49)

jodastephen

2,632 commits

cquiroz

634 commits

scala-steward

204 commits

sjmisterm

153 commits

cquiroz/scala-java-time

Implementation of the `java.time` API in scala. Especially useful for scala.js

Scala

130

4,113 commits

updated Sep 1, 2026

See the code

README

Scala Java-Time

build Maven Central Scala.js

This project provides an implementation of the java.time package, a date and time library that was added in Java 8. The implementation is based on the original BSD-licensed reference implementation (before it was contributed to OpenJDK).

Usage

The scala-java-time library is currently available for Scala (JVM, version 8 and later), Scala.js (JavaScript) and Scala Native (LLVM). Scala 2.11, Scala 2.12, Scala 2.13 and Scala 3.0.0 are supported.

To get started with SBT, add one (or both) of these dependencies:

  • libraryDependencies += "io.github.cquiroz" %%% "scala-java-time" % "2.6.0"
  • libraryDependencies += "io.github.cquiroz" %%% "scala-java-time-tzdb" % "2.6.0" (optional)

The second dependency contains all time zones available from IANA Time Zone Database. It can be removed if your code doesn't use timezones. Note that the timezone db is fairly large and due to the characteristics of the API it’s not very ammenable to optimization. This database is published every now and then so it may be old. For current version and more possibilities, pleae see the Time Zone section in the documentation.

Documentation

See the documentation

scala
scalajs
time
timezones

Contributors

(top 30 of 49)

jodastephen

2,632 commits

cquiroz

634 commits

scala-steward

204 commits

sjmisterm

153 commits

Languages

Scala

99.3%