How to abort Widget Query in `beforequery` event


1 comment

  • Avatar
    Moti Granovsky (Edited )

    Hi Tin,

    Preventing a query from executing in the `beforequery` event is as simple as assigning an empty object `{}` to the `query` event argument.

    This will result in the query not being sent, and the widget rendering in its "no results" mode.


    widget.on('beforequery', function(ev, args) {
      args.query = {};

    Comment actions Permalink

Please sign in to leave a comment.