Skip to content
This repository has been archived by the owner on Aug 23, 2019. It is now read-only.
Shannon Moeller edited this page May 5, 2014 · 7 revisions

Don't replace or replicate native JS functions. Just make them more convenient to use.

Spiritual successor to MOUT, Lo-Dash, and Underscore. Pairs well with a nice set of polyfills.

var natural = require('mtil/array/sort/natural');
var pluck = require('mtil/array/pluck');
var toLookup = require('mtil/array/toLookup');
var unique = require('mtil/array/unique');

var customers = [ ... ];
var names = customers.map(pluck('name')).filter(unique()).sort(natural);
var index = customers.reduce(toLookup('name'), {});
Clone this wiki locally