fune/toolkit/content/vendor/lit/README.md
Stanca Serban 6219c6dbcb Backed out 2 changesets (bug 1801426, bug 1790483) for causing bc failures on browser_all_files_referenced.js. CLOSED TREE
Backed out changeset af5a48a4b3d3 (bug 1801426)
Backed out changeset f4f8e2b95246 (bug 1790483)
2022-11-23 03:09:29 +02:00

812 B

Vendoring for lit

lit can be used to help create Web Components.

The lit.all.mjs bundle

The lit package is imported in a vendoring step and the contents are extracted into the lit.all.mjs file. This has some differences from using lit in a regular npm project. Imports that would normally be into a specific file are pulled directly from the lit.all.mjs file.

eg.

// Standard npm package:
import { LitElement } from "lit";
import { classMap } from "lit/directives/class-map.js";

// Using lit.all.mjs (pathing to lit.all.mjs may differ)
import { classMap, LitElement } from "../vendor/lit.all.mjs";

## To update the lit bundle

Using `mach`s `npm` you can update the bundle with:

cd toolkit/content/vendor/lit ../../../../mach npm run vendor


Then commit the changes.