Table — Remote API & Virtual Window

Mode

Skin

Theme

Sidebar

3 Architectural Modes for ln-table

Ashlar provides three distinct architectural paradigms for data grids, allowing you to choose the exact trade-off between SEO/initial paint, client memory, and network throughput:

  • 1. SSR Pre-Rendered Table

    HTML <tr> DOM elements emitted by backend (PHP/Node). Instant initial paint & SEO. Zero client template compile. In-memory DOM sorting & filtering.

    View SSR Demo →
  • 2. Remote API & Virtual Window (Active)

    Paginates infinite backend data on-demand via ln-api-connector. Ideal for huge databases (100k+ records) with server-side SQL/querying.

    Active Demo
  • 3. Injected JSON Seed

    Backend injects 1,000+ JSON records directly into <script type="application/json">. Ingested into ln-data-store in 0ms. Rendered via Cheetah/Glide virtual DOM row recycling pool (~35 recycled rows).

    View Injected Seed Demo →

Overview & Architecture

This page demonstrates a pure Client-Side Data Architecture coordinating ln-table and ln-api-connector via ln-data-coordinator, with no client-side store. There are no pre-rendered SSR rows in <tbody> — rows are fetched remotely from the backend (api.php) on demand and rendered dynamically using <template data-ln-template="hybrid-docs-row">.

Data Flow & Lifecycle

  1. Mount & Request Initial. On initialization, ln-table enters sliding-window mode and emits ln-table:request-data for page 0.
  2. Transport. ln-data-coordinator forwards the request to ln-api-connector, which fetches the page (offset/limit) from api.php and returns it to the table's window cache. There is no client-side store and no IndexedDB.
  3. Template Rendering. ln-table ingests the records and stamps them out via hybrid-docs-row template into <tbody>.
  4. Virtual Windowing. As the user scrolls, ln-table requests page-aligned slices and keeps at most 1,000 rows resident, while only the viewport rows are in the DOM. A new search, sort or filter restarts the window at page 0.

What each control is wired to

The toolbar search and department/status popovers dispatch to ln-data-coordinator (hybrid-docs). Each sortable header carries an ln-sort control whose ln-sort:change event is intercepted. The ln-data-coordinator coordinates fetching new pages from the backend (api.php) via the ln-api-connector and delivering them to the table's window.

Integration Log Terminal


	

Interactive Table Demo

Documents Manager

Title
Department
Status
Priority
Owner
Size
Updated

items