Skip to content

Instantly share code, notes, and snippets.

@andershaig
Last active October 1, 2015 07:08
Show Gist options
  • Save andershaig/1943115 to your computer and use it in GitHub Desktop.
Save andershaig/1943115 to your computer and use it in GitHub Desktop.
Widget Refresh Completed
$(document).on('didRefreshWidgetContent', function () {
// Do something
});
@andershaig
Copy link
Author

This event is fired whenever a user completes an interaction with a plugin (i.e. submits a signup form, a poll or voting app vote, a stories answer, etc.). Depending on how the plugin is configured, they may first be prompted to share on Facebook. After that, the plugin calls a Javascript function that reloads the page from the server, selectively swaps out the content areas for the particular plugin (identified by the marker blocks in the liquid template), and finally triggers this event.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment