nesh icon indicating copy to clipboard operation
nesh copied to clipboard

Switching from underscore to lodash

Open ccheever opened this issue 10 years ago • 1 comments

Lodash is a drop-in replacement for underscore that is faster and more actively maintained. Since it is drop-in compatible, switching to it is trivial. The require statements are just changed from lines like _ = require 'underscore' to _ = require 'lodash-node'

Tested plan: Ran cake test and manually tested a few things

See: http://joefleming.net/posts/use-lodash-instead-of-underscore/ http://stackoverflow.com/questions/13789618/differences-between-lodash-and-u

ccheever avatar Mar 24 '14 23:03 ccheever

@ccheever looks like older NPM versions don't support the new ^version default syntax. It causes the build to fail:

https://travis-ci.org/danielgtaylor/nesh/jobs/21470912#L38

Can you change the dependency on lodash to use ~version instead, which is the old default? Also please rebase on master if possible so we don't get the merge commit above. Thanks!

danielgtaylor avatar Mar 26 '14 14:03 danielgtaylor