Find file History
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
..
Failed to load latest commit information.
component.js
component.json
dependencies.html
example.html
picture.jpg
readme.md

readme.md

Tangular-Time

A simple Tangular template engine helper for rendering humanable date and time.

Outputs:

  • now
  • 5 minutes ago
  • 1 month ago
  • 2 years ago

Usage:

<h1>{{ name }}</h1>
<div>{{ created | time }}</div>

or

console.log(Thelpers.time(new Date()));

Improvements

New: Tangular helper time2 performs updating of time every minute automatically.