summaryrefslogtreecommitdiff
path: root/static/js/lafargue.js
blob: 33c8e901597dcc6292eaeedd39970f4cd710897d (plain)
1
2
3
4
5
6
7
8
9
jQuery(function($) {
    if (WebSocket) {
        var websocket_base = $('head').attr('data-websocket-base');
        var socket = new WebSocket(websocket_base + '/lafargue/events');
        socket.onmessage = function(event) {
            $('.lafargue-list').prepend(event.data);
        };
    }
});