Vector math for JavaScript.