Skip to main content

<ImageBackgroundComponent/>

This component configures sets an image background for a SurfaceComponent or PaperComponent, and pastes it at the surface/paper origin.

Usage

Declare the image background component inside a SurfaceComponent, SurfaceProvider, PaperComponent or PaperProvider and provide it a url:

<script>
</script>
<SurfaceComponent renderOptions={renderOptions}>
...
<ImageBackgroundComponent url="/img/351032562.jpg"/>
</SurfaceComponent>

Props

ImageBackgroundComponentProps
Props for the ImageBackgroundComponent
NameTypeDescription
urlstringURL of the image to load.