@gibme/webserver
    Preparing search index...

    Type Alias Application

    Application: express.Application & {
        host: string;
        localUrl: string;
        port: number;
        protected: ProtectedRouter;
        server: Server;
        ssl: boolean;
        start: () => Promise<void>;
        static: (
            path: PathParams,
            local_path: string,
            options?: ServeStaticOptions,
        ) => void;
        stop: () => Promise<void>;
        tunnel: Tunnel;
        url: string;
        ws: WebSocket.RequestHandler;
        wsApplyTo: WebSocket.ApplyTo;
        wsServer: WebSocket.Server;
    }

    Type declaration

    • Readonlyhost: string

      The hostname the server is bound to

    • ReadonlylocalUrl: string

      The local URL of the server

    • Readonlyport: number

      The port the server is bound to

    • Readonlyprotected: ProtectedRouter

      Access to easy to use protected routes that automatically insert middleware that checks with the authentication provider for permitted access.

    • Readonlyserver: Server

      The underlying HTTP/s server instance

    • Readonlyssl: boolean

      Whether this server is answering SSL requests

    • start: () => Promise<void>

      Starts the server

    • static: (path: PathParams, local_path: string, options?: ServeStaticOptions) => void

      Serves static files from the specified path

    • stop: () => Promise<void>

      Stops the server

    • Readonlytunnel: Tunnel

      The cloudflared tunnel instance

    • Readonlyurl: string

      The public URL of the server

    • ws: WebSocket.RequestHandler

      Creates a WebSocket route in the same kind of format as .get/.post/etc

    • wsApplyTo: WebSocket.ApplyTo

      Applies the WebSocket middleware to the specified Router

    • ReadonlywsServer: WebSocket.Server

      Returns the WebSocket.Server instance attached to the application