-
-
Notifications
You must be signed in to change notification settings - Fork 3.3k
Description
The @connect
decorator, by default, appears to add a very aggressive shouldComponentUpdate
hook to the decorated component. This is great if Redux and props are the only sources of statefulness in your app - but that's not always true and leads to some seriously confusing behavior with non-obvious workarounds when it's not.
This is a known issue, of course, with react-router 0.13, but I'm having the same issue with react-intl's IntlMixin
, which adds localization data to context. And I get the feeling that this is going to keep happening as long as the React ecosystem is as fragmented as it is right now.
It would be really nice to just be able to throw an option on the @connect
ed components that I know are impure (or, similar to React core's PureRenderMixin
, throw an option on the ones I know are pure; there's certainly room for debate as to whether opt-in or opt-out is the right choice here).