ng-time-from-pipe

1.0.2 • Public • Published

ng-time-from-pipe

npm npm GitHub issues NPM Build Status

A simple pipe to display the time passed from the input date. Also includes a <time-from> component with hover switching effect (switch between time from and raw date format).

Updates as time passes.

Install

npm install ng-time-from-pipe

Usage

You can import in the @NgModule.

import { TimeFromPipeModule } from "ng-time-from-pipe";

then add to imports array.

@NgModule( { 
  declarations: [ ... ],
  imports: [ ..., TimeFromPipeModule, ... ]
})

you can choose between the time from pipe and the time from component (time from component has hover effect).

<time-from [value]="date"></time-from>
Attribute Type
value Input date toe be formated
<span>{{ date | timeFrom  }}</span>
Attribute Type
value Any. Date to be formated
isOn Boolean. Turns on and off pipe

Package Sidebar

Install

npm i ng-time-from-pipe

Weekly Downloads

10

Version

1.0.2

License

MIT

Unpacked Size

12.2 kB

Total Files

15

Last publish

Collaborators

  • harrison.barker