You can redirect the customer to login page when logout
the apps.
Example looks like –
import
{ Injectable } from
'@angular/core';
import
{ Router } from
'@angular/router';
@Injectable()
export
class AuthService
{
constructor( private
router: Router){}
authSignOut(){
localStorage.removeItem('Customer');
localStorage.removeItem('_AuthToken');
this.router.navigate(['Login']);
}
}
I hope you are enjoying with this post! Please
share with you friends. Thank you!!