Thank you for being patient! We're working hard on resolving the issue
The Lona SDK is split across four published packages with explicit audiences. Picking the right entry point makes the rest of your code read predictably.
| Package | Audience | When you import it |
|---|---|---|
@tento-lona | Everyday SDK consumers — app code, integration tests | You're building on top of Lona: open sheets, list rows, subscribe to changes, fetch events / tasks / preferences. |
@tento-lona/sheets | Data-model consumers — row-shape readers, encoders, fixture writers | You need wire-format types (Dtype, CellEntry, RowKey), built-in encodings, alias templates, system rows, or a backend implementation. |
@tento-lona/platform | Platform implementors — CLI, TUI, native renderers, future canvas back-ends | You're writing a new front-end that consumes the per-type plugin contract, scene + diff pipeline, tree pipeline, layout math, plugin data providers, or the TUI reference impl. |
@tento-lona/sheets-ui | DOM hosts — browsers, Electron, web-views | You're rendering sheets in a DOM. Provides Sheet, DOM_PLATFORM, the per-type DOM plugins, and the gesture system. |
Every package has its own lib.ts barrel. Reach for the barrel
that matches your audience — deep imports past it (e.g.
@tento-lona/clients/<name>) signal that the wrong barrel was picked,
and a CI guard test (tento/tento-lona-js/sheets/tests/platform-barrel-stability.deno.test.ts)
fails if a known-bad deep import re-appears.
import { LonaSdk, SheetHandle, RowClient, CalendarClient, EventsClient, TasksClient, PreferencesClient, Network } from "@tento-lona";import { Actor, InvalidationSink, RowDataChanged } from "@tento-lona"; (re-exported from rows for convenience)import { Sheet, SheetRow, RowKey, Dtype, CellEntry, EVENT_V1 } from "@tento-lona/sheets";import { PER_TYPE_SPECS, RenderScene, buildScene, diffScene, TreeWatcher, calendarListDataProvider, TuiReconciler, resolveAliasActiveLayout } from "@tento-lona/platform";import { Sheet, DOM_PLATFORM, RenderPluginManager, SheetDelegate, GestureCoordinator } from "@tento-lona/sheets-ui";The following are SDK-internal and not exported from any public barrel:
SheetLispLibrary,
extractFormulaDependencies, makeComputeRange. App-facing
formula entry-points live under SheetLispEnvironment,
evaluateFormula, and makeSheetView on @tento-lona.RowHandle, ClientContext,
IndexFactory, SubscribeHandle, SubscribeOptions. App code
never instantiates these directly; the indices
(EventsIndex, TasksIndex, DataIndex, RegressionIndex) are
the public surface.ChartViewModel. Pure data-side primitives
(LinearYScaler, castData, formatValue, GraphData,
ChartPointerStore, DiscreteConvolution) live on
@tento-lona/sheets and are the supported scaler API.If a missing name blocks you, file an issue. Re-introducing the internal export should be a deliberate decision, not a workaround.
@tento-lona/sheets library — row-shape readers, encoders, fixture writers@tento-lona/cli/rows-fixtures — rows fixture CLI tooling@tento-lona/cli — SDK command-line toolingtento/tento-lona-js/sheets/tests/platform-barrel-stability.deno.test.ts — the
CI guard that locks in the audience separation.