JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 4
  • Score
    100M100P100Q56244F
  • License MIT

Renders a <time> element that autoupdates at a configurable interval

Package Exports

  • react-autoupdate-time

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (react-autoupdate-time) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

react-autoupdate-time

Renders a <time> element that autoupdates at a configurable interval.

var date = new Date();
<AutoupdateTime value={date} />

Set custom update interval (defaults to 3000 miliseconds).

var date = new Date();
<AutoupdateTime value={date} interval=1000 />

Uses moment.js internally to render a relative time e.g. "an hour ago".