SSE
This commit is contained in:
@@ -16,6 +16,12 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
var es = new ReconnectingEventSource('/events/');
|
||||
es.addEventListener('message', function (e) {
|
||||
console.log(e.data);location.reload();false
|
||||
})
|
||||
</script>
|
||||
|
||||
{% endblock %}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user