timestamp-to-date

1.1.0 • Public • Published

timestamp-to-date

Returns date on 'yyyy-MM-dd HH:mm:ss' format from timestamp

Installation

$ npm i timestamp-to-date

Usage

'use strict'
 
const timestampToDate = require('.timestampToDate');
console.log(timestampToDate('1484448039504','yyyy-MM-dd HH:mm:ss')) // => 2017-01-15 10:40:39
console.log(timestampToDate('1484448039504','yyyy-MM-dd')) // => 2017-01-15
 

Readme

Keywords

none

Package Sidebar

Install

npm i timestamp-to-date

Weekly Downloads

643

Version

1.1.0

License

MIT

Last publish

Collaborators

  • wulv