Skip to content

free-drawingInfinite canvas drawing for any web page

A whiteboard in one element. Draw, organize and share ideas with tools, layers, frames, live collaboration and exports, in TypeScript and without framework.

free-drawing logo

A roadmap drawn with free-drawing: frame, cards linked by arrows, shapes, freehand strokes and a highlight

Quick start ​

Install the library with Konva, its only peer dependency:

bash
yarn add @fabwcie/free-drawing konva
bash
npm install @fabwcie/free-drawing konva
bash
pnpm add @fabwcie/free-drawing konva

Then give it an element of your page:

js
import { Drawer } from '@fabwcie/free-drawing';
import '@fabwcie/free-drawing/style.css';

const drawer = new Drawer(document.getElementById('drawer'), {
  theme: 'system', // light, dark or the one of the device
  language: 'auto', // language of the browser
});

// drawing changed: keep it anywhere as JSON
drawer.on('drawer.change', () => console.log(drawer.getDrawingFile()));

The guide describes every option, the features page shows what the drawer can do, the plugins guide shows how to add your own features and the API documents each class and method.

Open source ​

free-drawing is released under the MIT License. Issues and contributions are welcome on GitHub, see how to contribute.