Skip to content

Latest commit

 

History

History
46 lines (28 loc) · 1.41 KB

File metadata and controls

46 lines (28 loc) · 1.41 KB

datedog

a tiny library to calculate the days of two certain dates or find the date some days before / after a certain date

Build Status codecov npm npm Code Climate GitHub license

features

  • calculate the interval days between two dates
  • find the date xx days after a certain date whose default is today
  • find the date xx days before a certain date whose default is today

usage

cli

  1. npm install datedog -g
  2. datedog -h to see the usage

server

  1. npm install datedog --save
  2. const datedog = require('datedog')

broswer

  1. <script src="datedog.js"></script>
  2. use datedog as a global variable

documentation

calcDateInterval(dateFrom[, dateTo])

calcAfter(daysSince[, dateFrom])

calcBefore(daysAgo[, dateTo])

license

MIT