wirestate-react
Commands
| Name | Description |
|---|---|
| CommandExecutor | Represents the function returned by useCommandExecutor. |
| OptionalCommandExecutor | Represents the function returned by useOptionalCommandExecutor. |
| useCommandExecutor | Returns a stable function to dispatch commands on the active container. |
| useCommandHandler | Registers a command handler for the component's lifetime. |
| useOptionalCommandExecutor | Returns a stable function to dispatch optional commands on the active container. |
Context
| Function | Description |
|---|---|
| useContainer | Returns the active container from the context. |
| useScope | Returns a WireScope instance bound to the active container. |
Events
| Name | Description |
|---|---|
| EventEmitter | Represents the function returned by useEventEmitter. |
| useEvent | Subscribes a component to a specific event type on the EventBus. |
| useEventEmitter | Returns a stable function to emit events via the EventBus. |
| useEvents | Subscribes a component to multiple event types on the EventBus. |
| useEventsHandler | Subscribes a component to all events on the EventBus without type filtering. |
Injection
| Function | Description |
|---|---|
| useInjection | Resolves a service or constant from the active container. |
| useOptionalInjection | Safely resolves a value from the container, returning a fallback or null if not bound. |
Provision
| Name | Description |
|---|---|
| ContainerProviderProps | Represents props for ContainerProvider. |
| SubContainerProviderProps | Represents props for SubContainerProvider. |
| ContainerProvider | Provides a root Wirestate container to a React subtree. |
| SubContainerProvider | Provides a managed child container under the nearest parent container. |
Queries
| Name | Description |
|---|---|
| AsyncQueryExecutor | Represents the function returned by useAsyncQueryExecutor. |
| OptionalAsyncQueryExecutor | Represents the function returned by useOptionalAsyncQueryExecutor. |
| OptionalQueryExecutor | Represents the unction returned by useOptionalQueryExecutor. |
| QueryExecutor | Represents the function returned by useQueryExecutor. |
| QueryResponder | Represents the function that answers a query. |
| useAsyncQueryExecutor | Returns a stable function to dispatch async-capable queries on the active container. |
| useOptionalAsyncQueryExecutor | Returns a stable function to dispatch optional async-capable queries on the active container. |
| useOptionalQueryExecutor | Returns a stable function to dispatch optional synchronous queries on the active container. |
| useQueryExecutor | Returns a stable function to dispatch synchronous queries on the active container. |
| useQueryHandler | Registers a query handler for the component's lifetime. |