GridKit
size10KB gzippeddeps0 depslicenseMITgithubStar

The layout engine
for modern apps

Pixel-perfect drag, resize from any direction, collision detection. Framework-agnostic. 10KB.

Try the Playground →
Revenue
Users
Growth
Sales
Orders
Traffic
Perf
Score

See it in action

Drag, resize, and reorder — all at 60fps.

GridKit Playground
RECORDING
Revenue
Users
Growth
Sales
Orders
Traffic
Drag anywhereResize from any edgeAuto-collision60fps smooth

Before vs After

Replace 3 packages with one.

Without GridKit

  • • masonry-layout + @angular/cdk + angular2-draggable
  • • setTimeout 2000ms hack
  • declare var Masonry: any
  • • Broken on mobile/touch
  • • No animations
3 deps · 85KB · 3 days

With GridKit

import { GridKit } from 'gridkit-layout'

GridKit.create('#el', {
  collision: true,
  animate: true
})
0 deps · 10KB · 5 minutes

Everything. Built in.

Every feature runs live below — no static screenshots.

↕ ↔

Freeform Drag

Pixel-level precision. Smooth 60fps pointer tracking.

80×50

8-Handle Resize

All edges and corners. Min/max constraints enforced.

A
B ↓
Overlapping...

Collision Detection

Overlapping widgets auto-push. O(n log n) sweep-line.

Desktop · 3 col
1
2
3

Responsive Breakpoints

Auto-switch layouts by container width. Like CSS but smarter.

Drag From Outside

Drop widgets from a sidebar or toolbox into the grid.

W

Undo / Redo

Full history stack. Ctrl+Z friendly. 50-state memory.

Tab + Arrows

Keyboard Navigation

Tab to focus, arrows to move, Shift+arrows to resize.

Parent
c
c
Parent 2

Nested Grids

Grids inside grids. Isolated events. Cross-grid drag.

Server
Hydrate
Interactive

SSR / Headless

Compute layouts server-side. Zero DOM. Pure functions.

ReactVueSvelteAngularVanilla

Framework Agnostic

Core works everywhere. React & Vue hooks included.

10KB gzipped

Tiny Bundle

Tree-shakeable. Import only what you use.

0dependencies

Zero Deps

Pure TypeScript. No jQuery, no runtime bloat.

Simple API

Three lines to a working layout.

import { GridKit } from 'gridkit-layout'

const grid = GridKit.create('#dashboard', {
  collision: true,
  animate: true,
  onChange: (items) => saveLayout(items)
})

grid.add({ id: '1', x: 0, y: 0, w: 400, h: 200 })
grid.add({ id: '2', x: 410, y: 0, w: 200, h: 200 })

Works everywhere

Framework-agnostic core. First-class TypeScript.

ReactAngularVueSvelteVanilla JS

Ready to ship?

Build your dashboard in minutes, not months.