I see what you are saying; you could very well use a switch operator as well. The concept here was to demonstrate how you can wrap RenderIf to create a richer API for your JSX.
I've used it on several projects where teams were really happy with it. I'm curious why you think it is a "huge" mess considering the alternatives and potential pitfalls?
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
This looks really nasty. It's always better to such keep logic out of jsx. We have a switch operator for that.
I see what you are saying; you could very well use a switch operator as well. The concept here was to demonstrate how you can wrap
RenderIf
to create a richer API for your JSX.What I'm saying is that RenderIf is a huge mess and should not be used
I've used it on several projects where teams were really happy with it. I'm curious why you think it is a "huge" mess considering the alternatives and potential pitfalls?