diff --git a/src/app/profiles/page.tsx b/src/app/profiles/page.tsx index 5d25d86..2c552d8 100644 --- a/src/app/profiles/page.tsx +++ b/src/app/profiles/page.tsx @@ -3,14 +3,17 @@ import React, { useEffect, useState } from 'react' import { getPublicProfiles } from '../lib/actions' import { UserInfo } from '../lib/models' import UserProfileCard from '../lib/components/UserProfileCard' +import LoadingView from '../views/LoadingView' function Profiles() { const [profiles, setProfiles] = useState([]) + const [isLoading, setIsLoading] = useState(true) useEffect(() => { async function fetchData() { let p = await getPublicProfiles() setProfiles([...p]) + setIsLoading(false) } fetchData() }, []) @@ -19,6 +22,7 @@ function Profiles() {

Profiles

Members of our amazing community:
+ {isLoading && }
{profiles.map((p, i) => )}