Reminds me of a project in which we ended up using a very small applet working in the background to co-ordinate between ecmascript in the browser (using com.netscape.javascript.*) and interacting with the server through a persistent connection (using java.net.*) No need from browser refresh for small updates, it handled the UI event handling and was less than 10kb. This was around 1998 so it's kind of fuzzy, but I remember it worked well.
I definitely remember that it seemed sort of weird at the time getting the Netscape javascript classes to work in Internet Explorer on the Mac os9.