import { UUID } from "crypto"; import { BrainUser } from "./components"; import { useBrainUsers } from "./hooks/useBrainUsers"; type BrainUsersProps = { brainId: UUID; }; export const BrainUsers = ({ brainId }: BrainUsersProps): JSX.Element => { const { brainUsers, fetchBrainUsers, isFetchingBrainUsers } = useBrainUsers(brainId); if (isFetchingBrainUsers) { return

Loading...

; } if (brainUsers.length === 0) { return

No brainUsers

; } return ( <> {brainUsers.map((subscription) => ( ))} ); };