siwi-datehelper

2.0.2 • Public • Published

node Build Status npm npm Github file size

siwi-datehelper

install

use npm

npm install siwi-datehelper

use yarn

yarn add siwi-datehelper

demo

const expect = require('chai').expect
const dateHelper = require('siwi-datehelper')
describe('index.js', () => {
    it('time', async () => {
        const t = await dateHelper.time()
        console.log(t);
        expect(t).to.be.an('number')
    });
    it('Format', async () => {
        const f = await dateHelper.date_format()
        console.log(f);
        expect(f).to.be.a('string')
    });
    it('friendly', async () => {
        const time = await dateHelper.time()
        const f = await dateHelper.friendly(time - 340000)
        console.log(f);
        expect(f).to.be.a('string')
    });
});

Package Sidebar

Install

npm i siwi-datehelper

Weekly Downloads

1

Version

2.0.2

License

MIT

Unpacked Size

11.2 kB

Total Files

7

Last publish

Collaborators

  • siwi