← Back to API
On chatbox load
olark('api.chat.onReady', function(){
// Your callback function
});
Notes
Use this API call to detect when the Olark chatbox has loaded. You can create your own callback function once the onReady event fires.
For example, you would use onReady if you need to manipulate elements on your page only when you know for sure that Olark has loaded. You might be doing an A/B test for live chat, and want to send an event to your analytics when Olark has loaded on a page.