Hands the community feed, the latest things the site's members did in
public, to whatever shows it: the GeoCities style's marquee, for now.
CommunityFeedProvider provides this context and useCommunityFeed reads
it.
I
CommunityFeedContextValue
Provided by CommunityFeedProvider through CommunityFeedContext.
-
feed: CommunityFeed | null
Null until it is fetched, which waits for a first watch, and always for a visitor: the feed is for signed-in users.
-
watch: () => () => void
Says a component is showing the feed, until the returned call. The feed is fetched, and kept up to date, only while one is: most styles show it nowhere.
useCommunityFeedcalls it.
v
CommunityFeedContext: React.Context<CommunityFeedContextValue>
Provided by CommunityFeedProvider, and read with useCommunityFeed.
v
defaultCommunityFeedValue: CommunityFeedContextValue
Given to a consumer outside CommunityFeedProvider: no feed.
Usage
import * as mod from "src/contexts/social/CommunityFeedContext.ts";