Theme Framework How the LeaseLeads theme frontend works

Core Concepts

The JavaScript framework — the instance model, composition, loading, and why each works as it does.

Abstract watercolour by Sohrab Sepehri

The machinery under every component. These pages lean on why and how to use, not line-by-line mechanics — the load-bearing decisions are called out inline as Why it works this way notes.

  1. Instantiable & the instance model — the base every behaviour extends.
  2. The lifecycleboot → afterBoot → init, and what belongs in each.
  3. Traits — how a component composes many capabilities at once.
  4. The Globals registry — the runtime registry and its external API.
  5. The AssetLoader pipeline — how a selector becomes a loaded, running component.
  6. Two-phase loading — Crucial, Deferred, and the performance story.
  7. Sub-components & HasX — how a host discovers and drives what's inside it.