View Engine reference
This reference describes the current 5.0.0 workspace contract. The package has not yet been published to the public registry; follow the local build/archive instructions. Repository development requires Node >=20.20.2 and pnpm 10.34.5. React UI requires React/ReactDOM ^19.2.8; direct dependencies are installed with the package and their declared peers must also be satisfied.
| Entry | Contents | Runtime |
|---|---|---|
@ahoo-wang/fetcher-view-engine | Models, ViewHost, ViewEngine, pure filter/analysis helpers, MemoryViewHost | Core import does not load React, DOM or CSS |
@ahoo-wang/fetcher-view-engine/react | useViewEngine, ViewPage, RecordView, AnalysisView, FilterPanel, table/card presentations and built-in controls | React 19 and browser UI |
@ahoo-wang/fetcher-view-engine/styles.css | Compiled scoped styles | Import once in the application |
No consumer Tailwind or React Compiler plugin is required. fve: is the CSS utility prefix, not a prefix for configured component names. The current implementation supports record table/card views and kind: 'analysis' tables, metric cards, bar/line/area charts and pie/donut charts.
| Contract | Topic |
|---|---|
| Definition, instance, filter configuration and source shape | Models |
| Service facade, permissions, revisions and development storage | ViewHost |
| Headless lifecycle, commands and snapshots | ViewEngine |
| Filter serialization, compiler and remote candidates | Filters |
| React ownership, extension props, cells and theme | Components |
| Every exported name in both code entries | Symbol index |
Use task guides for integration steps and the shared runnable example for a verified starting point. Files under dev, internal engine services and private UI primitives are not additional public imports.
The required ViewDefinition.record.allowedLayouts controls available layouts; a single allowed layout hides the switch. Switching retains each layout configuration; see the model contract.
