v0.8 • UI • 10kb gzipped • MIT
DrawLite
A whiteboard primitive: strokes, shapes and undo, with the collaboration layer left to you.

// why drawlite
A primitive, not a product
DrawLite handles input, rendering and history. Persistence and collaboration stay in your hands, where your architecture already lives.
// stack
Pointer-native
One pointer path covers mouse, touch and stylus, including pressure where the hardware reports it.
DrawLite started as a single file in a client project and stayed small on purpose. It does one job, it does it in 10kb gzipped, and it has no runtime dependencies.
Getting started
Install it, import it, call it:
npm i drawlite-js
DrawLite handles input, rendering and history. Persistence and collaboration stay in your hands, where your architecture already lives.
What it does not do
It does not manage your state, style your components or ship a plugin system. Those are your decisions, and keeping them out is what keeps the bundle honest.
- Branching history
- Pressure and tilt
- MIT licensed, commercially friendly
Features
Branching history
Undo and redo across branches, so exploring an idea never destroys the previous one.
Pressure and tilt
Stylus input is read properly rather than flattened to a fixed stroke width.
Styling stays yours
DrawLite sets no colours and no spacing. Every visual decision belongs to your design system.
Dark mode ready
Reads from CSS custom properties, so a theme switch needs no JavaScript at all.
Container aware
Adapts to the box it is given rather than the viewport, so it works in a sidebar.
Accessibility audited
Tested against screen readers on three platforms, with the findings published in the repository.
Get DrawLite v0.8
11 files • .min.js 10kb • .zip 72kb • sha384 verified
Changelog
- Branching undo history
- Stylus pressure and tilt support
- Stroke smoothing is now optional
- Safari 16 compatibility fixes
- Bundle size reduced by eleven percent
- Improved error messages for invalid options
- Added twenty regression tests
// related
Related products
PulseGrid
Headless data table with sorting and virtual scroll that stays smooth at a hundred thousand rows.
View →ToastKit
Accessible toast notifications in two kilobytes, with a queue that never talks over itself.
View →DialogJS
Focus-trapped dialogs built on the native element, with the edge cases already handled.
View →Ship the interface today.
MIT licensed. Commercial friendly. Five-minute setup.