This repository has been archived by the owner on Sep 10, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
should isReferentiallyTransparentFunctionComponent
be completely off for non-production env?
#442
Comments
deepsweet
changed the title
should
should Jul 24, 2017
isReferentiallyTransparentFunctionComponent
be completely off not for production?isReferentiallyTransparentFunctionComponent
be completely off for non-production env?
Also it sounds like a breaking change because it might break many tests based on children count or (which is more likely) Jest snapshots.
One can't expect much performance from React in dev mode, all of these warnings, PropTypes, setter guards, and so on :) As for me it's totally fine. |
Guys, sorry for pushing, but is there any conclusion? Plans for the next major version? |
I remember about this, just took a few weeks break with any computer work. Now Im drinking vodka with bears in deep Russia and have mobile phone only ;-) |
You can provide a PR with 90% probability we will accept it |
Sorry for late reply and yes, a PR is welcome. This change probably can land at 0.25. 🐻 |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hi.
Right now
from here leads to lack of actual element while testing with Enzyme (
NODE_ENV=test
) so very dummy stateless components can't be found in a tree. Same problem with react-dev-tools (NODE_ENV=development
), I can't see the component because function was directly invoked with props.I understand the purpose of
createEagerFactory
, and the idea is really nice, but in my opinion it should be production only optimization. Should we consider removing|| !Component.propTypes
part from the condition or something like this? It's really confusing and took a lot of time to find the reason.The text was updated successfully, but these errors were encountered: