JavaScript 通讯框架 NowJS

码农软件 · 软件分类 · Node.js 扩展 · 2019-04-17 13:28:08

软件介绍

NowJS 是一个实现了 JavaScript 服务器端进行通讯的框架,基于 Node.js 开发。

示例代码:

服务器端:

<script src="/nowjs/now.js"></script>
var everyone = require("now").initialize(httpServer); everyone.now.getServerInfo = function(callback){ db.doQuery(callback); return "done!" }
everyone.now.distributeMessage = function(message){ everyone.now.receiveMessage(this.now.name, message); };

客户端代码:

<script type="text/javascript" src="http://localhost:8080/nowjs/now.js"></script>

<script type="text/javascript">
  now.ready(function(){
    // alerts "Hello World!"
    alert(now.msg);
  });
</script>

本文地址:https://codercto.com/soft/d/3778.html

Developing Large Web Applications

Developing Large Web Applications

Kyle Loudon / Yahoo Press / 2010-3-15 / USD 34.99

As web applications grow, so do the challenges. These applications need to live up to demanding performance requirements, and be reliable around the clock every day of the year. And they need to withs......一起来看看 《Developing Large Web Applications》 这本书的介绍吧!

Base64 编码/解码
Base64 编码/解码

Base64 编码/解码

Markdown 在线编辑器
Markdown 在线编辑器

Markdown 在线编辑器