When developing games or physics simulations you probably (and should) have already used vectors.
npm install vector
var Vector = Vector;v1 = 10 30;v2 = 30 40;v1;v1;v1;
You can also use it directly on the browser. Just copy the lib/vector.js to a public folder on your app.
Vector.js is written in CoffeeScript, so if you want to make a contribution, edit the src/vector.coffee and generate the js by running
cake build or
All the unit tests are also written in CoffeeScript. To run then, just type