pretty-time-webcomponent

0.5.1 • Public • Published

pretty-time-(webcomponent)

A simple ultra lightweight VanillaJS Webcomponent to display time.

Installation

npm i -S pretty-time-webcomponent

Usage

Include pretty-time.js:

    <head>
      <!-- if you want to support legacy browser add the webcomponents-loader -->
      <!-- <script src="node_modules/@webcomponents/webcomponentsjs/webcomponents-loader.js"></script> -->
      <script type="module" src="node_modules/pretty-time-webcomponent/pretty-time.js"></script>
      ...
      
    <body>
      <pretty-time milliseconds="16208020"></pretty-time>

4h 30m 8s

See the demo.html for examples.

Dependencies (1)

Dev Dependencies (0)

    Package Sidebar

    Install

    npm i pretty-time-webcomponent

    Weekly Downloads

    0

    Version

    0.5.1

    License

    MIT

    Unpacked Size

    4.99 kB

    Total Files

    5

    Last publish

    Collaborators

    • toarm