Weave.js

WeaveBrushToolAction

Paint freeform strokes on the canvas

Overview

The WeaveBrushToolAction class that enables users to draw freeform strokes on the canvas using a brush tool. It lets users click and drag across the canvas to create a smooth, continuous path—perfect for sketching, annotating, or freehand drawing within a collaborative environment.

Each stroke is recorded as a WeaveLineNode, synchronized across all connected users in real time.

The class extends the WeaveAction class.

Name

This action name property value is brushTool.

Import

import { WeaveBrushToolAction } from "@inditextech/weave-sdk";

Instantiation

new WeaveBrushToolAction();