this.currentUser$=this.afs.doc('users/'+this.authState.uid).valueChanges().pipe();
When I include it in my component.html file like this:
{{ currentUser$|async|json}}
The output I get is as follows:
{
"photoUrl": "",
"password": "",
"mobileVerified": true,
"id": "izoNRvk0moN579KqfQ1cVqNvpZJ2",
"phone": "5544663311",
"email": "<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="4322272e2a2d03263b222e332f266d202c2e">[email protected]</a>",
"name": "Rob B",
"oscar-winner": "admin"
}
If you want to access only the email
or userRole
, how can you achieve that?