setup_component_observers
is an internal function that 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.
setup_component_observers(
component_id,
type,
session,
components,
shared_state,
on_selection_change,
registry = NULL
)
List of observer objects created for the specified component type. Throws Error if an unsupported component type is provided.
Character string. Unique identifier for the component.
Character string. The type of component to set up observers for. Currently supports "leaflet" and "datatable".
'shiny' session object. The current 'shiny' session.
List. Collection of all components in the application.
Reactive values object. Shared state across components.
Function. Callback function to execute when selection changes occur.
Optional. Registry object for component management. Default is NULL.