Something went wrong. Try again.
Monorepo for the nibling.run platform
Something went wrong. Try again.
1234567891011121314151617181920// node:https, loadable and refusing: the bridge carries plain HTTP/1.1 exchanges, so// there is no TLS server to create, and outbound requests wait for the http client.import { refused, refusedClass } from "./refuse";
const SERVER_WHY = "guest servers speak plain HTTP over the Service Worker bridge";const CLIENT_WHY = "the http client is not implemented yet";
const Agent = refusedClass("https", "Agent", CLIENT_WHY);
export const https = { createServer: refused("https", "createServer", SERVER_WHY), Server: refusedClass("https", "Server", SERVER_WHY), request: refused("https", "request", CLIENT_WHY), get: refused("https", "get", CLIENT_WHY), Agent, // An instance (not `new Agent()`, which refuses) so imports that read it at load // time, as some HTTP clients do, see an Agent-shaped object rather than nothing. globalAgent: Object.create(Agent.prototype) as object,};