Functional tools for JavaScript