Re:Show HN: In-view.js – Get notified when DOM elements ente...
by Heqx on Saturday August 27, 2016 @02:01PM
(#12373409)
Can you point me to an explanation of the differences between the 'lodash.throttle' module and importing 'lodash/throttle'?
[ Parent
| on HN ]
Re:Show HN: In-view.js – Get notified when DOM elements ente...
by jdd on Sunday August 28, 2016 @02:19AM
(#12375518)
lodash.throttle is a standalone zero-dependency package of just the throttle module. The `lodash` package is a collection of modules one of which is `lodash/throttle`.
You can generally get smaller bundles using `lodash/xyz` modules over the `lodash.xyz` packages because of plugins like:
https://github.com/lodash/babel-plugin-lodash
https://github.com/lodash/lodash-webpack-plugin
Though in the future lodash-webpack-plugin may support `lodash.xyz` packages too.
Re:Show HN: In-view.js – Get notified when DOM elements ente...
by freditup on Saturday August 27, 2016 @08:02PM
(#12374723)
You should get about the same results using a bundler. Perhaps the lodash.throttle package is for reducing `npm install` time or reducing bloat if you check in your node modules?