All Downloads are FREE. Search and download functionalities are using the official Maven repository.

wvlet.log.LogTimestampFormatter.scala Maven / Gradle / Ivy

There is a newer version: 24.12.2
Show newest version
package wvlet.log

import scala.scalajs.js

/**
  * Use scalajs.js.Date to foramte timestamp
  */
object LogTimestampFormatter {
  def formatTimestamp(timeMillis: Long): String = {
    new js.Date(timeMillis.toDouble).toISOString()
  }

  def formatTimestampWithNoSpaace(timeMillis: Long): String = {
    new js.Date(timeMillis.toDouble).toISOString()
  }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy