bezier-kit

A zero-dependency TypeScript library for cubic bezier curves. Works with both 2D and 3D through the same API — morphing, splitting, arc-length queries, and path generation.

Interactive demos

canvas-morph

React · Canvas 2D

Interpolate between two randomly generated 2D bezier paths with createPathInterpolator, then split and separate the halves with createPathSplitter using color coding and offset.

threejs-tube

React · @react-three/fiber · 3D

Build a 3D curve from random points with fromCatmullRom<Point3D>, render it as a THREE.TubeGeometry, and visualize morphing and splitting in 3D space.