I’m sure you must’ve seen react components where there are a bunch of props being passed down, and almost always the majority of those props are boolean flags. These flags help you conditionally show a specific part of the component in a different way or sometimes even completely remove that part from the render tree. But this approach is a scaling nightmare. This component is now open to “one-off“ condition blocks.
⏱️ 6 minutes read
#React
Post #1076
11.7K