MCPcopy Create free account
hub / github.com/auth0-samples/auth0-ionic-samples / Profile

Function Profile

react/src/components/Profile.tsx:4–22  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2import { IonAvatar } from "@ionic/react";
3
4const Profile: React.FC = () => {
5 const { user, isLoading } = useAuth0();
6
7 if (isLoading) {
8 return <div>Loading ...</div>;
9 }
10
11 if (!user) return null;
12
13 return (
14 <div className="profile-container">
15 <IonAvatar className="avatar">
16 <img src={user.picture} alt={user.name} />
17 </IonAvatar>
18 <h2>{user.name}</h2>
19 <p>{user.email}</p>
20 </div>
21 );
22};
23
24export default Profile;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected