Documentation / @finchart/core / index / DrawSurface
Interface: DrawSurface
Defined in: packages/core/src/render/types.ts:165
The surface a picture actually lands on. The single owner of size.
context exists only when there's a canvas — a surface that doesn't replay commands (headless — a recording renderer just receives commands) only holds size. Whoever actually requires a context (createCanvasRenderer, createCanvasTextMeasurer) throws at construction if it's missing — a wiring error, not a quiet null object.
Properties
context?
readonlyoptionalcontext?:Canvas2DContext
Defined in: packages/core/src/render/types.ts:168
height
readonlyheight:number
Defined in: packages/core/src/render/types.ts:167
width
readonlywidth:number
Defined in: packages/core/src/render/types.ts:166