-
Notifications
You must be signed in to change notification settings - Fork 801
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hot reloading "fat arrow function" in component not possible #221
Comments
This is not currently supported and in fact unlikely to ever be supported in React Hot Loader because it transpiles to an assignment inside a constructor. We might have a solution based on Babel which will handle this, in the future. |
Sorry for posting in closed issue. I guess this is still relevant to v3? Sadly 1. we have a lot of state in UI components 2. We use the arrow way everywhere Was testing upgrade to v3 |
I know this is old, but I've established what I think of as an acceptable workflow for using fat arrow click handlers with hot reload. Basically just make a copy of the click handler within your render function, and replace the
|
This code works fine with hot reloading:
But when I extract the handler into a variable, it still works functionally but it doesn't hot-reload:
Any thoughts on this?
The text was updated successfully, but these errors were encountered: