User data is in local storage, you can retrieve it. Here is an example of the code:
Place the code below in the Other Functions (TypeScript) field:
userName:string = `No Login` ;
userEmail:string = `-` ;
public ngOnInit(){
this.storage.get("current_user").then((current_user)=>{
console.log(`storage`, `current_user`, current_user);
if (current_user && current_user.token){
this.userName = current_user.user_name ;
this.userEmail = current_user.user_email ;
}else{
this.userName = `Anonymous` ;
this.userEmail = `~` ;
}
});
}
Then you can display the username in Page Content (HTML5) like this:
{{ userName }}