Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rudifa/spk-lit-js
Sample web components from Lit documentation
https://github.com/rudifa/spk-lit-js
Last synced: 24 days ago
JSON representation
Sample web components from Lit documentation
- Host: GitHub
- URL: https://github.com/rudifa/spk-lit-js
- Owner: rudifa
- License: isc
- Created: 2021-11-13T15:00:08.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2022-04-18T17:43:10.000Z (over 2 years ago)
- Last Synced: 2024-10-06T01:41:21.708Z (about 1 month ago)
- Language: JavaScript
- Homepage:
- Size: 112 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Sample components from Lit documentation
[Overview](https://lit.dev/docs/components/overview/)
[Lit docs](https://lit.dev/docs/)
[Lit Playground](https://lit.dev/playground/)## New Project
> ✨ Bootstrapped with Create Snowpack App (CSA) with [app-template-lit-element](https://github.com/snowpackjs/snowpack/tree/main/create-snowpack-app/app-template-lit-element).
> ✨ Adapted by [rudifa](https://github.com/rudifa) to use Lit ^2.0.2 (instead of lit-element ^2.4.0, lit-html ^1.4.0
## Usage
>✨ Use it as a starter template for similar projects - remove the sample components and add your own.
## Available Scripts
### npm start
Runs the app in the development mode.
Open http://localhost:8080 to view it in the browser.The page will reload if you make edits.
You will also see any lint errors in the console.### npm run build
Builds the app for production to the `dist/` folder.
It correctly bundles the app in production mode and optimizes the build for the best performance.## Directives
In case you need to add a directive like `classMap` you should add the extension to the import:
```
import { classMap } from "lit-html/directives/class-map.js";
```