node-webot / weixin-robot

微信公共帐号自动回复机器人 A Node.js robot for wechat.
1.76k stars 555 forks source link

建议把node-expat换为纯JS的实现,如node-xml #10

Closed atian25 closed 11 years ago

atian25 commented 11 years ago

很多虚拟主机如nae, cloudfoundry都是不支持c++的类库的. 建议换为pure javascript的类库.

PS1: 本想写个类库的, 却发现仁兄把我想写的都写了....

PS2: 正在看waitor那块,因为想做的东西是有流程的,而不仅仅是一两个来回的问答

atian25 commented 11 years ago

刚才以为是用了类库把json转为xml的, 仔细看了下源码,xml是直接拼字符串的, 而xml转json是用xml2json,这个类库引入了node-expat 建议换为xml2js

atian25 commented 11 years ago

简单修改了下。引入xml2js, 去掉xml2json。 只变更了lib里面的类,对应的test,example,bin没有修改。

在cloudfoundry试过可以使用。

PS: 自带的example有点小bug,被折腾了半天...