Use setInterval instead of setTimeout on the extension
This commit is contained in:
parent
b4da667a5e
commit
e4d6f1f117
|
@ -33,7 +33,7 @@
|
|||
setInterval(function() {
|
||||
const data = { tag: "PERFORM_EXTENSION_SETUP" };
|
||||
window.postMessage(data, "/");
|
||||
}, 300); // Give some time to the extension for registering the listener
|
||||
}, 300); // Send it many times, in case the extension had not registered the listener yet
|
||||
</script>
|
||||
{% endif %}
|
||||
|
||||
|
|
|
@ -20,10 +20,10 @@
|
|||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
setTimeout(function() {
|
||||
setInterval(function() {
|
||||
const data = { tag: "PERFORM_EXTENSION_SETUP" };
|
||||
window.postMessage(data, "/");
|
||||
}, 300);
|
||||
}, 300); // Send it many times, in case the extension had not registered the listener yet
|
||||
</script>
|
||||
|
||||
{% endblock %}
|
Loading…
Reference in New Issue