I just want to show one div if the user is logged in already or else I want to show another div with different content. Can anyone guide this to achieve this?
SAP Spartacus - How to find wheter the user is logged in or not
767 views Asked by Selva Ajitha At
1
You'd use the
authService.isUserLoggedIn()
method, that exposes an observable.You could use it like this:
In your component controller you'd addd the
isLoggedIn
property: