Rabbit Ear


var myOrigami = ear.origami()

This is a Javascript library for modeling, designing, and diagramming origami.


This library is in pre-release.

The online editor is the fastest way to start coding:


The library is one Javascript file, available from Github CDN, NPM, or for download.

npm install rabbit-ear
rabbit-ear.js (~180kb)


Look for this button next to all the sketches in these docs, this will open the editor with the sketch's code.


Full web apps build with Rabbit Ear.

Let's Begin

Ready? Head over to Chapter 1: Math. For the coders, here's some tips to take with you.

Rabbit Ear is composed of smaller libraries (the four chapters), and is even further divided into a front end and a back end. The front end is the object-oriented style objects with class methods, these constructors are at the top level, for example:

ear.vector(1, 2, 3)

Ideally you never leave the front end, but this might not be possible especially in the early days of this library. You can tell you're venturing into the back end when you begin seeing snake_case. Back-end methods are grouped by categories.


Categories; notice some of these double as constructors (graph, svg).

The front end calls the back end, and you can too, but back-end methods are meant to execute as fast as possible so you will need to ensure arguments are in the correct form. Front-end objects and methods will type-check your arguments and try best not to throw errors.


This library is written in ES6 Javascript. The source code is on Github.