This internal function creates and configures observers for different types of interactive components based on the specified component type. It acts as a dispatcher that calls the appropriate setup function for each supported component.
Usage
setup_component_observers(
component_id,
type,
session,
components,
shared_state,
on_selection_change,
registry = NULL
)
Arguments
- component_id
Character string. Unique identifier for the component.
- type
Character string. The type of component to set up observers for. Currently supports "leaflet" and "datatable".
- session
Shiny session object. The current Shiny session.
- components
List. Collection of all components in the application.
Reactive values object. Shared state across components.
- on_selection_change
Function. Callback function to execute when selection changes occur.
- registry
Optional. Registry object for component management. Default is NULL.