examples/websocket-chat-ts-run/web-server/public/js/client.js
function initUserList(data) {
	users = data.users;
	for(var i = 0; i < users.length; i++) {
		var slElement = $(document.createElement("option"));
		slElement.attr("value", users[i]);
		slElement.text(users[i]);
		$("#usersList").append(slElement);
	}
}
function initUserList(data) {
	users = data.users;
	for(var i = 0; i < users.length; i++) {
		var slElement = $(document.createElement("option"));
		slElement.attr("value", users[i]);
		slElement.text(users[i]);
		$("#usersList").append(slElement);
	}
}
function initUserList ( data ) { users = data . users ; for ( var i = 0 ; i < users . length ; i ++ ) { var slElement = $ ( document . createElement ( "option" ) ) ; slElement . attr ( "value" , users [ i ] ) ; slElement . text ( users [ i ] ) ; $ ( "#usersList" ) . append ( slElement ) ; } }
init user list
init user list