artboard-deluxe / createArtboard
createArtboard()
createArtboard(
providedRootEl,initPlugins,initOptions):Artboard
Defined in: artboard/createArtboard.ts:31
Create a new artboard instance.
Parameters
providedRootEl
The root element.
Must be an element that creates a new stacking context (e.g. position: relative) when using the dom() plugin. When using canvas rendering, this should be the canvas.
HTMLElement | HTMLCanvasElement
initPlugins
ArtboardPluginDefinition<any, any>[] = []
The plugins to initialise the artboard with.
Plugins can also be added afterwards using the artboard.addPlugin() method.
initOptions
ArtboardOptions = {}
The init options.
To update options after the artboard is initialised, use the artboard.setOption() and artboard.setOptions() methods.