href » NowJS
NowJS is a cool abstraction layer that tries to emulate a shared stack between the server (NodeJS) and clients (browsers). You end up with something like this on the server:
var everyone = require("now").initialize(httpServer);
everyone.now.getServerInfo = function(callback) {
db.doQuery(callback);
}
Which allows you to do this on the client:
<script type="text/javascript">
now.getServerInfo(function(data) {
// data contains the query results
});
</script>
It uses Socket.IO under the hood to keep the data in sync, so it should use WebSockets when available, and fallback to alternatives when needed.