Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

english-time-mirror

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

english-time-mirror

Parses times written in simple English to unix time

  • 0.0.9
  • latest
  • npm
  • Socket score

Version published
Weekly downloads
3
increased by200%
Maintainers
1
Weekly downloads
 
Created
Source

english-time Build Status

Parses times written in simple English to unix time.

time = require('english-time')

time('314 milliseconds')
// => 314

time('5 minutes 15 seconds')
// => 315000

time('an hour and a minute')
// => 3660000

time('1 Hour, 5 Minutes And 15 Seconds')
// => 3915000

time('2h 15m 15s')
// => 3915000

time('3 weeks, 5 days, 6 hours')
// => 2268000000

time('3 weeks, 5d 6h')
// => 2268000000

See List of Recognized Unit Aliases and tests for more info.

Install

$ npm install english-time
## List of Recognized Unit Aliases

Milliseconds

  • ms
  • millisec
  • millisecs
  • milliseconds
  • millisecond

Second(s)

  • s
  • sec
  • secs
  • seconds
  • second

Minute(s)

  • m
  • min
  • mins
  • minute
  • minutes

Hour(s)

  • h
  • hour
  • hours

Day(s)

  • d
  • day
  • days

Week(s)

  • w
  • week
  • weeks

Month(s)

  • mo
  • month
  • months

Year(s)

  • y
  • year
  • years

Translations

Tools & libraries based on english-time

FAQs

Package last updated on 23 Mar 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc