Skip to content

Glossary

Alphabetical definitions for all terms used across the MVT documentation. Each entry links to the page where the concept is explained in depth.

Related: Architecture Rules · Style Guide · Project Structure


TermDefinition
Barrel fileAn index.ts that re-exports the public API of a directory module. All cross-directory imports must go through the barrel. Project Structure
BindingsA plain object bridging view and model. Contains get*() accessors for reading state and on*() handlers for relaying user input. Bindings · Bindings in Depth
Change detectionA technique where the view polls a binding each frame and acts only when the value differs from the previous frame. Avoids expensive rebuilds for infrequently changing state. Change Detection
deltaMsMilliseconds elapsed since the last tick. The sole mechanism by which time flows into models. Models · Time Management
Domain unitsPosition, distance, and velocity units meaningful to the game domain (tiles, world-units, slots) rather than presentation-layer measures (pixels, points). Models
Factory functionA createXxx(options) function that returns an object satisfying an interface. Used instead of classes for encapsulation via closures. This is a project convention, not an MVT requirement. Style Guide
Frame sequenceThe strict per-frame order: model.update(deltaMs) then view.refresh() then the renderer draws. The Ticker
GSAP timelineA paused GSAP timeline used inside models to tween state over time, advanced manually via update(deltaMs). Never auto-playing. This is a project convention for time management, not an MVT requirement. Time Management
Hot pathCode that runs every tick (~60fps) - update() and refresh() and everything they call. Must avoid unnecessary allocations. Hot Paths
Leap-safe modelA model whose update() produces correct results for any deltaMs size (including large leaps). Purely arithmetic models are typically leap-safe; GSAP-based models with orchestration guards are typically not. Time Management
ModelA stateful object that owns domain logic and advances via update(deltaMs). Has no knowledge of views or rendering. Models
MVTModel-View-Ticker. An architecture for visual, interactive applications that separates state from presentation with a ticker-driven frame loop. What is MVT?
Presentation stateLimited view-internal state used purely for cosmetic transitions (e.g. animating a score counter). The exception to the "views are stateless" rule. Presentation State
refresh()A view's per-frame function that reads bindings and updates the presentation output to match current state. Called after all models have updated. Views
Skills fileA self-contained instruction document that an AI agent can load for a specific task (writing a model, writing a view, following code conventions). Located in docs/ai-agents/.
TickerThe frame loop that drives the application: calls model.update(deltaMs), then view.refresh(), then the renderer draws. The Ticker
update(deltaMs)A model's per-frame method that advances state based on elapsed milliseconds. The sole mechanism for time to flow into a model. Models · Time Management
ViewA stateless renderer that reads state through bindings (or model properties, for top-level views) and writes to the presentation output via refresh(). Views
WatchA helper (watch()) that accepts a record of named getter functions, polls them each frame, and reports which values changed. Each watched property exposes changed, value, and previous. Change Detection