yc-battery

0.1.3 • Public • Published

YC-Battery

An example of a webcomponent using Lit-element.

Installation

npm install yc-battery

or using yarn:

yarn add yc-battery

Usage

Recommended way: in a lit template (see also, demo folder):

import { html, render } from 'lit-html';
import '../src/YCBattery.js';

const app = document.getElementById('myApp');

const template = html`
  <yc-battery .fillAmount=${30}></yc-battery>
`;

render(template, app);

Regular usage in html:

<!DOCTYPE html>
<html lang="en">
  <head>
    <script type="module">
      import 'yc-battery/yc-battery.js';
    </script>
  </head>
  <body>
    <yc-battery fillAmount="10"></yc-battery>
  </body>
</html>

Readme

Keywords

none

Package Sidebar

Install

npm i yc-battery

Weekly Downloads

3

Version

0.1.3

License

MIT

Unpacked Size

4.52 kB

Total Files

6

Last publish

Collaborators

  • jorenbroekema