Callbacks and Delegates
onReady is the single API for session tracking. It supports two call patterns:
Promise (all architectures)
Resolves once when FullStory has initialized and started session capture.
Listener (New Architecture only)
Subscribes to every session start. The callback fires immediately if a session is already active, and again for each subsequent session. Returns a subscription object with a remove method to unsubscribe.
note
The listener overload onReady(callback) is only supported on the New Architecture. On the Old Architecture, calling onReady with a callback logs a warning and returns a no-op subscription. Use the Promise-based API for compatibility across both architectures.