You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
filepizza/client/socket.js

13 lines
291 B
JavaScript

import io from 'socket.io-client';
import Actions from './Actions';
var socket = module.exports = io.connect(window.location.origin);
socket.on('token', function (token) {
Actions.updateToken(token);
});
socket.on('download', function (peerID) {
Actions.sendToDownloader(peerID);
});