UNPKG

stream-chat-react-native-core

Version:

The official React Native and Expo components for Stream Chat, a service for building chat applications

9 lines (6 loc) 291 B
import type { Channel } from 'stream-chat'; import { useChannelMembershipState } from '../../../hooks/useChannelMembershipState'; export const useIsChannelPinned = (channel: Channel) => { const membership = useChannelMembershipState(channel); return Boolean(membership?.pinned_at); };