// // Create API enabled reference to the widget (note that we are passing DOM object) widget = SC.Widget($('body').find('iframe')[0]); // Interact with widget via API widget.bind('ready', function () { alert('widget ready'); }); }); }());