When you are creating an Ionic app with different roles, chances are high you need different elements/pages for your different user roles. In case of the Ionic side menu, you can easily display different menu elements to your users based on their login role to create role specific Ionic apps!
In this Quick Win we will develop a side menu with dummy login for 2 different users. The admin user should see some admin pages while the regular user can only see his pages.
Remember: In a real world scenario you need to plug in a real backend with authentication! But there’s a JWT course inside the Ionic Academy that helps you setup everything.
The final result of our logic looks like this:
The full quick win with snippets is only available to Ionic Academy members.
Join now for
- Unlimited access to all quick wins
- Library of 40+ step-by-step video courses
- Support for Ionic questions via Slack & private community