Skip to content

Interface: RenderRootOptions ​

Experimental

Properties ​

PropertyTypeDescription
antialias?booleanExperimental MSAA for geometry edges. Default true.
background?RGBA | nullExperimental Canvas clear color (sRGB 0–1). null = transparent. Default opaque white.
createRenderer?(parameters) => WebGLRendererExperimental Injectable renderer factory (tests, or custom renderer setup).
height?numberExperimental
maxPixelRatio?numberExperimental Upper limit of the automatic pixel ratio. Default 2.
overlay?booleanExperimental Create the figure-level overlay viewport. Default true.
pixelRatio?numberExperimental Device pixel ratio. Default min(devicePixelRatio, maxPixelRatio), re-evaluated when the DPR changes.
powerPreference?WebGLPowerPreferenceExperimental
preserveDrawingBuffer?booleanExperimental Needed for toDataURL after the frame on a root with its own context. Default false. A shared root's canvas always keeps its pixels.
responsive?booleanExperimental Resize with the container via ResizeObserver. Default true.
scheduler?FrameSchedulerExperimental Injectable frame scheduler (tests). Default: requestAnimationFrame.
shared?boolean | "auto"Experimental Draw through a renderer shared with other roots instead of taking a WebGL context (ADR-023). 'auto' shares once MAX_DEDICATED_CONTEXTS roots own a context, and never with a custom createRenderer. Default false.
width?numberExperimental Fixed CSS size when not responsive (defaults to the container's size at creation).

Released under the MIT License.