Skip to main content

Type Alias: TwoDPreviewService

TwoDPreviewService = PreviewService & object

Contract for a 2D preview rendering engine, sharing the view lifecycle exposed by ThreeDPreviewService in @repo/preview-3d via PreviewService. Renders real SVG/DOM content into registered views - crisp at any zoom for free, updated via React's own reconciliation rather than a full re-render per change.

Type Declaration​

setElement()​

setElement(element): void

Updates the content rendered into every registered view, and re-renders them immediately. Call whenever the underlying design/layout data changes.

Parameters​

element​

ReactNode

Returns​

void