make client work from either node or the browser!
notes
update examples
update server