Skip to content

Files

Latest commit

d90d8fc · Nov 16, 2023

History

History
26 lines (18 loc) · 504 Bytes

README.md

File metadata and controls

26 lines (18 loc) · 504 Bytes

paintbricks

An extendable drawing system built for the web.

Install

npm install --save paintbricks

Usage

// import manager and tool
import {Manager, PenTool} from "paintbricks";

// Create a new manager
const manager = new Manager(canvasElem, canvasWidth, canvasHeight);

// create a new pen tool with color and stroke width
const penTool = new PenTool("blue", 5);

// set the current tool as the pen tool
manager.setTool(penTool);

// ... draw :)