Overview
useEntity reads from the nearest EntityProvider in the component tree and returns the entity’s state and actions. It does not fetch data itself — it accesses what EntityProvider has already loaded.
useEntity must be used inside an EntityProvider. See EntityProvider & useEntity for setup instructions.Usage Example
Return Values
The current entity.
undefined while loading, null if not found.Direct state setter for the entity. Use for manual local state overrides.
Updates the entity on the server and syncs local state. Accepts
title, content, attachments, keywords, location, metadata, and mentions.Deletes the entity and sets local state to
undefined.
