Made backspace work on input history items

This commit is contained in:
khlieng 2015-02-12 02:14:56 +01:00
parent 8a790a6fe2
commit b7cafc5327
4 changed files with 9 additions and 5 deletions

View file

@ -2,6 +2,8 @@ var EventEmitter = require('events').EventEmitter;
var _ = require('lodash');
var ws = new WebSocket('ws://' + window.location.host + '/ws');
var socket = {
send: function(type, data) {
ws.send(JSON.stringify({ type: type, request: data }));
@ -10,8 +12,6 @@ var socket = {
_.extend(socket, EventEmitter.prototype);
var ws = new WebSocket('ws://' + window.location.host + '/ws');
ws.onopen = function() {
socket.emit('connect');
};