Open jeremyjannotta opened 12 years ago
Tested the case of initializing the same element twice, like $el.liveBlogLiteUi().liveBlogLiteUi();
which is weird, but caused the liveBlogLiteApi code to duplicate API requests. Added fix in commit https://github.com/aol/liveblog-widget/commit/37b7d4036bb32024c5f9441323720dc247c19fbb that simply prevents the liveBlogLiteApi from initializing twice on the same object. More testing needs to be done though, including testing two unique widget elements on a page.
Technically we should be able to load more than one instance of the widget on the page. We need to test if loading or initializing the plugin twice on a page causes weird behavior, and make sure that variable scoping and event binding is isolated to each instance.