1.0.1 • Published 8 years ago
think-socket-uws v1.0.1
ThinkJS Socket.io uWebSocket
ThinkJS 2.x Socket.io adapter, that's implement uWebsockets
Install
npm install think-socket-uws
How to use
register adapter
import uws from 'think-socket-uws';
think.adapter('websocket', 'uws', uws);
add above code in bootstrap file, like src/common/boostrap/adapter.js
.
change view type
change adapter type in file src/common/config/websocket.js
,
export default {
type: 'uws',
adapter: {
uws: { //uws socket.io options
}
}
}