<script>
addEventListener('load', function() {
  opener.postMessage({ type: 'LOADED' }, '*');
});

addEventListener('pageshow', function() {
  opener.postMessage({ type: 'PAGESHOW' }, '*');
});
</script>
