sketch

Sketch canvas drawing component

Sketch

Turn a canvas into a sketch pad.

$ component install component/sketch

Turn the given canvas into a sketch pad.

var sketch = require('sketch');
sketch(canvas);

Add drawable object that must provide a .draw(ctx) method.

Set pen size.

Set pen color.

Set pen opacity.

Clear the objects and re-draw.

Reset the sketch defaults and clear the canvas.

MIT