ConstprojectInterface that the project must support. The networkObject in
the ready state has the project data provider interface type associated with this
projectInterface.
String id of the project to get, or a project data provider to
pass straight through, or undefined for noSource
OptionalpdpFactoryId: stringOptional ID of the PDP factory to get the project data provider from
The NetworkObjectState of the project data provider
Gets the state of the project data provider for a project: which of "no project given", "the lookup is in flight", "here it is", and "not available" it is in.
Prefer this over useProjectDataProvider whenever the project can change WITHOUT the consumer remounting — a web view that re-points itself with
updateWebViewDefinition({ projectId }), or one that follows the active editor.useProjectDataProvideranswers such a change with the PREVIOUS project's provider and no way to tell, so a consumer reads one project's data under another's id and writes data derived from one into the other's storage. This union makes that window visible, and separates it from a lookup that failed and will not recover on its own.Act only on
ready. Whileloading, a consumer may keep displaying what it last rendered, but must not write through it — that distinction between what may be shown and what may be written is the point.The returned state keeps its identity across renders that do not change it, so it is safe to key memos and effects on.