@dashed just released a v1 of https://github.com/dashed/shallowequal which (among other improvements) removes the dependency on lodash.
Despite being a major version update, it does not have breaking API changes. Therefore, an update simply requires to bump the version in package.json and release a patch.
hmm... it seems deep-equal is being used in favour of shallowequal: https://github.com/nfl/react-helmet/pull/200
v3.2.2 still has it: https://github.com/nfl/react-helmet/blob/3.2.2/package.json
but v3.2.3 does not: https://github.com/nfl/react-helmet/blob/3.2.3/package.json
Oops. Opened an issue with a wrong repository. This was meant to be opened with https://github.com/gaearon/react-side-effect. react-helmet uses react-side-effect, react-side-effect uses shallowequal.
That said, react-helmet could replace deep-equal with shallowequal to reduce the dependency tree. (They do the same thing, right?)
@gajus apparently shallowequal latest release is breaking webpack production builds (uglify does not support let statements yet).
Just ran into this as well with shallowequal and Uglify.
@magalhas can you link where you found others having the same issue?
@gajus I believe we used deep-equal because with children the object comparison in shouldComponentUpdate was always false, even if the children were unchanged. We needed a way to truly check equality between children in props.
@cwelch5 Version of shallowequal has been pushed with the Uglify fix.
The issue came from... https://github.com/gaearon/react-side-effect/issues/36. Which came from... https://github.com/dashed/shallowequal/issues/8.
It's not react-helmet's responsiblity.
When react-side-effect was released from 1.1.0 to 1.1.1, changing shallowequal from 0.2.2 to 1.0.0.
Most helpful comment
@gajus apparently shallowequal latest release is breaking webpack production builds (uglify does not support let statements yet).