Basic websocket test on connect

This commit is contained in:
Jeremy Zhang
2017-08-19 05:09:13 +00:00
parent d7ac9fd9c9
commit 6b3ada44db
5 changed files with 18 additions and 1 deletions

View File

@ -7,6 +7,8 @@
/* global localStorage */
/* global visitors_enabled */
/* global cheet */
/* global location */
/* global io */
(function () {
const theme_options = ["DiscordDark", "BetterTitan"]; // All the avaliable theming names
@ -247,6 +249,12 @@
} else {
primeEmbed();
}
/* SocketIO Test */
var socket = io.connect(location.protocol + '//' + document.domain + ':' + location.port + "/gateway");
socket.on('connect', function() {
console.log("Socket.IO Connected!");
});
});
function changeTheme(theme=null, keep_custom_css=true) {