Skip to main content

Overview

useFetchEvent returns a callable that fetches one event by ID. Visibility is enforced server-side: if the event doesn’t exist or the logged-in user can’t see it, the request returns 404. Pass include to expand associations and populate userRsvp.

Usage Example

Parameters

string
required
The event ID.
string | string[]
Associations to expand: "user", "space", "files", "userRsvp".

Returns

Returns a Promise<Event> — the Event.

See Also