# ws-protocol-buffer **Repository Path**: jayjayo/ws-protocol-buffer ## Basic Information - **Project Name**: ws-protocol-buffer - **Description**: protocol buffer 在ws上的使用, 封装encode/decode方法. 增加proto文件封包工具. - **Primary Language**: NodeJS - **License**: MIT - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 1 - **Created**: 2019-07-16 - **Last Updated**: 2021-11-03 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README NodeJS Server (WebSocket & Protocol Buffer) === 本项目是使用NodeJS搭建的基于Protocol Buffer的WebSocket通信Demo, 希望能抛砖引玉. # 下载代码 git clone git@git.oschina.net:justinchou/ws-protocol-buffer.git cd ws-protocol-buffer npm install # 根据API生成Proto 编辑api.json, 定义接口 自动生成Message.proto文件 npm run genProto # 根据API功能, 填写好proto接口文件 参考google的proto文件编写 # 运行 运行server.js 运行client.js