dblencowe/time-string-formatter

Convert a string like 1W 2D to seconds

1.3.1 2017-01-22 20:36 UTC

This package is auto-updated.

Last update: 2024-12-07 00:01:48 UTC


README

Convert date string to seconds

Take a string (fox example 2d 6H) and convert it to seconds. Currently supports the following units:

  • W (Weeks)
  • D (Days)
  • H (Hours)
  • M (Minutes)
  • S (Seconds)