Helper for dynamically resolving the PubSub server to use.
This module provides functions to get the appropriate PubSub server based on configuration. It will use the configured pubsub from the parent application.
Configuration
Configure the PubSub server in your application:
config :phoenix_kit, pubsub: MyApp.PubSubIf not configured, PhoenixKit will attempt to derive it from the parent app name (e.g., MyApp -> MyApp.PubSub).
Summary
Functions
Broadcasts a message to a topic using the configured PubSub server.
Broadcasts a message using a specific PubSub server.
Gets the PubSub server module to use.
Gets the PubSub server from socket endpoint config.
Subscribes to a topic using the configured PubSub server.
Subscribes to a topic using a specific PubSub server.
Functions
Broadcasts a message to a topic using the configured PubSub server.
Broadcasts a message using a specific PubSub server.
Gets the PubSub server module to use.
Returns the configured pubsub server, or derives it from parent_module config.
Gets the PubSub server from socket endpoint config.
This is useful in LiveView contexts where the socket has access to the endpoint configuration.
Subscribes to a topic using the configured PubSub server.
Subscribes to a topic using a specific PubSub server.