Skip to content

Instantly share code, notes, and snippets.

@rajansurani
Created February 28, 2022 10:23
Show Gist options
  • Save rajansurani/82573c005bdc2695a66d12a060cfed12 to your computer and use it in GitHub Desktop.
Save rajansurani/82573c005bdc2695a66d12a060cfed12 to your computer and use it in GitHub Desktop.
//...function App(){}
//This function will accumulate the list of particiapnts and generate the ParticipantView for each participant in the meeting
const ParticipantsView = () => {
//Get the list of participants
const { participants } = useMeeting();
return (
<>
<h2 style={{ color: "#3E84F6" }}>Participants</h2>
<div
style={{
display: "flex",
flexWrap: "wrap",
flexDirection: "row",
padding: "8px",
}}
>
{[...participants.keys()].map((k) => (
<div style={{ }}>
<ParticipantView key={k} participantId={k} />
</div>
))}
</div>
</>
);
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment