teableio/teable

View on GitHub
packages/sdk/src/components/comment/hooks/useCollaborator.ts

Summary

Maintainability
A
0 mins
Test Coverage
import { useCollaborators } from './useCollaborators';

export const useCollaborator = (id: string) => {
  const collaborators = useCollaborators();
  return collaborators.find((collaborator) => collaborator.userId === id);
};