0.0.3 • Published 1 year ago

@reactively/lit v0.0.3

Weekly downloads
-
License
ISC
Repository
-
Last release
1 year ago

Reactively

Reactively is a library for fine grained reactive programming.

See documentation for details.

This part of the library (@reactively/lit) provides integration with the Lit library for web components.

Here is an example using Lit and @reactively together.

  1. Inherit from ReactiveLitElement in place of LitElement
  2. Implement reactiveRender() instead of render(). (This enables @reactively/lit to track the reactive sources used while rendering, and to trigger re-rendering when necessary.)
  3. Choose how to annotate your reactive properties:
    • @reactiveProperty properties are reactive and visible as lit web component properties.
    • @reactively properties are reactive but not web component properties.
  4. Call stabilizeContinously() once when you start your application, so that all ReactiveLitElement instances will re-render() automatically.