Hi everyone. In my app, each user has a role. And there are a list of buttons that is generated based on role and some other criteria (online presence and so on). Basically, I have many nested Ifs. The code become complex, and it is difficult to add new buttons there. I’m looking for some patterns or advices how to structure code in this case.
Can we see your full project code?