A library modeled in JavaScript