Expose websocket server to plugins
Same reasoning used when exposing Express.
This commit is contained in:
7
typings/pluginapi.d.ts
vendored
7
typings/pluginapi.d.ts
vendored
@ -6,6 +6,7 @@ import * as express from "express"
|
||||
import * as expressCore from "express-serve-static-core"
|
||||
import ProxyServer from "http-proxy"
|
||||
import * as net from "net"
|
||||
import Websocket from "ws"
|
||||
|
||||
/**
|
||||
* Overlay
|
||||
@ -102,6 +103,11 @@ export interface WebsocketRouter {
|
||||
*/
|
||||
export function WsRouter(): WebsocketRouter
|
||||
|
||||
/**
|
||||
* The websocket server used by code-server.
|
||||
*/
|
||||
export const wss: Websocket.Server
|
||||
|
||||
/**
|
||||
* The Express import used by code-server.
|
||||
*
|
||||
@ -110,7 +116,6 @@ export function WsRouter(): WebsocketRouter
|
||||
* instances.
|
||||
*/
|
||||
export { express }
|
||||
|
||||
/**
|
||||
* Use to add a field to a log.
|
||||
*
|
||||
|
Reference in New Issue
Block a user