01
Headless core
A pure state machine with events. Render it with anything — or nothing, and test it in Node.
headless window manager · 0 dependencies
Drag, resize, snap, minimize, undo — a real desktop inside the page. Every window you see is the library doing its job. Grab one.
drag a titlebar to a screen edge to snap · ⌘⌥← / → snap · ⌘Z undo · F6 cycle · ? help
01 — build a window
A full editor: markup, CSS and placement on the left, a live window on the right. Drag it, restyle it, then copy the code or send it to the desktop above.
02 — capabilities
The core keeps state, the DOM layer moves pixels, your framework renders content. Each piece is replaceable.
01
A pure state machine with events. Render it with anything — or nothing, and test it in Node.
02
Halves, quarters, thirds and maximize on edge drop, plus 8px edge magnetism against neighbours.
03
Every interaction is one history entry. A drag is a single undo, not sixty move events.
04
Park windows on virtual desktops. Focus follows the window across workspaces.
05
Serialize to JSON, hydrate back, or drop in the persist plugin with versioned migrations.
06
Roles, labels, a focus trap for modals, keyboard control and a live region that narrates the desktop.
07
Pointer events throughout, adaptive hit areas on coarse pointers, long-press context menu.
08
Sixteen CSS themes ship with it — every value is a custom property, and a per-window variant overrides them for one window.
03 — adapters
Window content always lives in your own component tree — no innerHTML, no portals into the void. Adapters are thin sugar over the same state machine.
04 — landscape
The floating-window niche went quiet years ago. That is exactly why wmkit exists.
| Honest comparison | wmkit | react-rnd | dockview | winbox.js |
|---|---|---|---|---|
| Framework agnostic | yes | react only | core + React·Vue·Angular | yes |
| Headless core | yes | no | no | no |
| Snap zones | halves, quarters, thirds | none | dock grid | none |
| Undo / redo | built in | none | none | none |
| Workspaces | built in | none | none | none |
| Tab groups | drag to group | none | core feature | none |
| Serialize / restore | core + plugin | roll your own | yes | none |
| Keyboard control | move, resize, snap, cycle | none | partial | none |
| Live region for AT | yes | no | no | no |
| Content ownership | your tree | your tree | your tree | innerHTML |
| Bundle (brotli) | ~18 kB | ~15 kB | ~60 kB | ~10 kB |
Checked on July 26, 2026: last commits, npm downloads, open feature requests.
pnpm add @surdeddd/wmkit