In my script I have some custom js that needs to be refreshed after the views_flag_refresh completed. Looking through the code, it wasn't clear to me how to do this with the module itself.

I found a solution in jQuery.ajaxComplete. My view is a block.

  // re-add our custom js on completion
  $('#block .content').ajaxComplete(function(event, request, settings){
    // only update on the refresh GET, not the initial POST
    if(settings.type == "GET"){
      alerts_init();  // my custom function for refreshing the js
    }
  });

Is there a 'correct' way to accomplish this with this module?

Module devs: How does this solution look to you?

Any comments appreciated.
Thanks.