0.1.1 • Published 7 years ago

date-utility v0.1.1

Weekly downloads
4
License
MIT
Repository
github
Last release
7 years ago

Date-Utility

A small library that has some date verification and utilities.

Installation

npm install date-utility

Usage

const dateUtil = require('date-utility');

const currentYear = dateUtil.getCurrentYear();   // 2017
const age = dateUtil.getYearsSince(1944);   // 73
const formattedDate = dateUtil.getFormattedDate("01/01/2017")  //"2017-01-01"
const validDate = dateUtil.isValidDate("01/01/2017") //true

Tests

npm test

0.1.1

7 years ago

0.1.0

7 years ago