News for hackers. Stuff that matters.
Re:Show HN: React-decoration – A collection of decorators fo... by steve_taylor on Sunday October 30, 2016 @05:58AM (#12828940)
The great thing about React is that it's easy to reason about. Devs new to React can quickly come up to speed. When you start decorating React components like this, you're introducing magic and making React code less easy to reason about. I'm not saying that you should avoid this in all cases, but you should consider the pros and cons and be careful. It seems that decorators at the component class level provide a mechanism to bring back mixins for those who want to use ES6 React components with mixins.
Re:Show HN: React-decoration – A collection of decorators fo... by dismantlethesun on Sunday October 30, 2016 @06:36AM (#12829052)
Well I glanced in and saw a decorator for event functions, like a debounce for an onClick.

That seems like a whole different thing. Isn't it worth while?

Re:Show HN: React-decoration – A collection of decorators fo... by steve_taylor on Sunday October 30, 2016 @07:50AM (#12829284)
Decorating individual functions probably isn't a bad thing in those cases. The link takes you to only part of the Github repo. Look at the rest of it and you will see various class-level decorators.