Quick Start CanvasLayer
Get started with node-i2d to create rich visualisations on node platform.
Integrate source code as specified on the installation page.
Import node-i2djs module
let { canvasLayer } = require("node-i2djs");
Layer Creation:
node-I2Djs provides API's for Canvas, and PDF requirements. In this example, we will be using the Canvas context.
canvasLayer API returns Canvas-2D renderer instance. It accepts parameters - contextAttrObject, Height and Width. For more details on layer API, refer to API Reference > Layers
Element Creation:
Using renderer instance we will create a circle. createEl API is used to create the Element of type 'Circle' with attributes and style properties as specified below.
Apply changes to Canvas Layer
Last updated