Files
exploRUGComponent/docs-src/install.md
Kevin Schaaf fddb01149c Update lit-starter-ts to lit-next
* Upgrades the source to work with lit-next
* Aligns the linting and formatting rules/settings & ignores with the monorepo
* Upgrades to the same version of typescript and tsconfig settings as the monorepo
* Upgrades the test runner from karma to web-test-runner
* Upgrades the dev server from es-dev-server to @web/dev-server
2021-01-29 17:35:17 -08:00

782 B

layout, title
layout title
page.11ty.cjs <my-element> ⌲ Install

Install

<my-element> is distributed on npm, so you can install it locally or use it via npm CDNs like unpkg.com.

Local Installation

npm i my-element

CDN

npm CDNs like unpkg.com can directly serve files that have been published to npm. This works great for standard JavaScript modules that the browser can load natively.

For this element to work from unpkg.com specifically, you need to include the ?module query parameter, which tells unpkg.com to rewrite "bare" module specificers to full URLs.

HTML

<script type="module" src="https://unpkg.com/my-element?module"></script>

JavaScript

import {MyElement} from 'https://unpkg.com/my-element?module';