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
(refactor) move context update logic to diffing #1468
(refactor) move context update logic to diffing #1468
Conversation
Added some tests to see if this would introduce bugs in Context.Consumer but those come out positive aswell. |
…k/preact into refactor/contextLogicDiffing
Another approach could be to instead of use componentDidUpdate to use shouldComponentUpdate to notify subs, how are you standing on this? In comparison to doing a Approach in diffing: f77f265 |
…k/preact into refactor/contextLogicDiffing
@JoviDeCroock can you check your IDE settings? There are lots of mixed spaces and tabs as indentation in the same file 🙂 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Love it, the PR just got better and better! On top of that who can resist the byte savings 🎉 💯
I've made a first draft since it seems to solve the issue adressed by @marvinhagemeister with useContext.
Added the test in his branch here, and it works.
Will now look at how we can implement the others.
Size change:
+26B+17B-3B-10BFixes #1363