Kibana integration: tracking filters, etc external to iframe

Hi Kibana users!

I'm excited about my current project, because Elasticsearch and Kibana have proved to be exceptional tools.

I have some analysis that happens external to these systems and I would like to present all the data in one UI. To this end I have an iframe which houses an embedded Kibana dashboard. I'd like to know how I can monitor Kibana's (filters and other state) within the iframe so that I can keep the external analysis in sync.

My web developer tooling shows the 'src' attribute of the iframe does not change, and when I added a MutationObserver to the iframe (with attributes:true config), nothing was triggered. If I do document.getElementById('kibana').contentWindow.window.location.hash, I get get access to the filter via the hash, but I have no idea how to monitor this.

Any help gratefully received!
Dan.

The likely answer turns out to be popstate. Not massively easy to use for my use case, but that's not your problem :smile:

Still, any other suggestions appreciated.