Switch between nested Components with onClick @Dynamic Components

Hey Guys,

My name is Bjorn and I’d like to use the onClick method to switch between different Components
I’m creating a kitchen block, and I’d like all the cabinets to be clickable and automatically change from plain cabinets, to drawers, to something else etc.

I figured I need to create States. For example: To show only Cabinet A I need to make a State in which Cabinet B and C are hidden.

I guess I’m in the right direction, but I can’t figure out how to actually make this work.

Does any of you have an idea that could help me figuring this out?

1 Like


Please don’t create duplicate topics. I’ve already replied to this in your other thread: