Skip to content

substrate-system/input

Repository files navigation

input

tests types module install size GZip size dependencies semantic versioning Common Changelog license

A parent web component to inherit from.

See a live demo

Install

npm i -S @substrate-system/input

Modules

This exposes ESM and common JS via package.json exports field.

ESM

import { Input } from '@substrate-system/input'

Common JS

const { Input } = require('@substrate-system/input')

Use

Inherit from this module.

JS

import { Input } from '@substrate-system/input'

class FooBar extends Input {
    static tag = 'foo-bar'
}

// Use the static method `define`
FooBar.define()

document.body.innerHTML += `
    <foo-bar></foo-bar>
`