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

@tehshrike/duration-iso-8601

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@tehshrike/duration-iso-8601

Parse ISO 8601 Duration(PnYnMnDTnHnMnS syntax)

  • 2.0.1
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
2.6K
decreased by-61.16%
Maintainers
1
Weekly downloads
 
Created
Source

duration-iso-8601

Parse ISO 8601 Duration(PnYnMnDTnHnMnS syntax)

https://en.wikipedia.org/wiki/ISO_8601#Durations

Installation

npm install @tehshrike/duration-iso-8601
const parse = require('@tehshrike/duration-iso-8601')

Examples

parse('P1Y2M3DT4H5M6S') // => { year: 1, month: 2, day: 3, hour: 4, minute: 5, second: 6 }

parse('P1Y30DT15M39S') // => { year: 1, day: 30, minute: 15, second: 39 }

parse('ieurht834') // => null

Keywords

FAQs

Package last updated on 22 Jun 2020

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