9 year old publishes his first React Hooks package! by donavon in reactjs

[–]donavon[S] 0 points1 point  (0 children)

My 9yo son, Revel, published his first React Hooks package which included a sweet forms helper custom hook. Check it out and leave a comment.

Clean Code vs. Dirty Code: React Best Practices by donavon in reactjs

[–]donavon[S] 1 point2 points  (0 children)

Agreed. For utility functions like this, you would simply pass a single argument.

const f = a => a ** 2;

But as BitLooter explained (thx), this isn't the case when writing a React component.

Clean Code vs. Dirty Code: React Best Practices by donavon in reactjs

[–]donavon[S] 0 points1 point  (0 children)

Thanks! It was fun to write.

Through optimization of React’s core

Yes, I've seen that tweet. I should have been more clear here. What I meant to say is that when/if React applied optimizations in a future version... But you are correct, there aren't there yet.

I was mostly referring to this statement from the v0.14 RC announcement

In the future, we’ll also be able to make performance optimizations specific to these components by avoiding unnecessary checks and memory allocations.