Access to static functions · Issue #49 · jprichardson/string.js (original) (raw)

@jasonkuhrt

Static functions are readily composable in functional contexts.

var camelized = _.map([...], S.camelize);

I assume the rationale and use-cases are obvious so won't explain at length. string.js just needs to implement the same pattern as found in lodash, underscore:

1.   _.map(...)
2.   _(...).map

So to reiterate currently string.js only supports ^ 2 but 1 is desirable and there is no reason the styles cannot co-exist.