SnapshotComponent
SnapshotComponent API
- SnapshotComponent.doActivate
- Returns
- void
SnapshotComponent.doActivate(): void
Implements doActivate method.
- SnapshotComponent.createSnapshot
- Parameters
- userDrawCallback: (ctx: CanvasRenderingContext2D) => void
- - Optional callback function that takes a CanvasRenderingContext2D object as a parameter and allows the user to draw on the canvas before taking the snapshot.
- Returns
- Promise<Blob>
SnapshotComponent.createSnapshot(userDrawCallback: (ctx: CanvasRenderingContext2D) => void): Promise<Blob>
Creates a snapshot of the canvas and returns it as a Promise of Blob object.