BREAKING CHANGE(TypedSocket.createServer): Remove SmartExpress attachment support from createServer and upgrade smartsocket to ^3.0.0
This commit is contained in:
@@ -3,6 +3,6 @@
|
||||
*/
|
||||
export const commitinfo = {
|
||||
name: '@api.global/typedsocket',
|
||||
version: '3.1.1',
|
||||
version: '4.0.0',
|
||||
description: 'A library for creating typed WebSocket connections, supporting bi-directional communication with type safety.'
|
||||
}
|
||||
|
||||
@@ -38,16 +38,12 @@ export class TypedSocket {
|
||||
* note: this will fail in browser environments as server libs are not bundled.
|
||||
*/
|
||||
public static async createServer(
|
||||
typedrouterArg: plugins.typedrequest.TypedRouter,
|
||||
smartexpressServerArg?: any
|
||||
typedrouterArg: plugins.typedrequest.TypedRouter
|
||||
): Promise<TypedSocket> {
|
||||
const smartsocketServer = new plugins.smartsocket.Smartsocket({
|
||||
alias: 'typedsocketServer',
|
||||
port: 3000,
|
||||
});
|
||||
if (smartexpressServerArg) {
|
||||
smartsocketServer.setExternalServer('smartexpress', smartexpressServerArg);
|
||||
}
|
||||
|
||||
smartsocketServer.socketFunctions.add(
|
||||
new plugins.smartsocket.SocketFunction({
|
||||
|
||||
Reference in New Issue
Block a user