From 226f2fb218481ba35bda2d8e09b692c2651e4015 Mon Sep 17 00:00:00 2001 From: James M Snell Date: Sun, 5 Nov 2023 21:45:23 +0000 Subject: [PATCH] Update index.bs --- index.bs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/index.bs b/index.bs index 46df777..69abfea 100644 --- a/index.bs +++ b/index.bs @@ -8,6 +8,7 @@ URL: https://sockets-api.proposal.wintercg.org/ Repository: https://github.com/wintercg/proposal-sockets-api Editor: Dominik Picheta, Cloudflare https://cloudflare.com/, dominik@cloudflare.com Editor: Ethan Arrowood, Vercel https://vercel.com/, ethan.arrowood@vercel.com +Editor: James M Snell, Cloudflare https://cloudflare.com/, jsnell@cloudflare.com Abstract: Sockets API for Non-Browser EcmaScript-based runtimes. Markup Shorthands: markdown yes Markup Shorthands: idl yes @@ -42,6 +43,8 @@ A socket becomes closed when its {{close()}} method is called. A socket c

Connect

+

The [=connect=] method here is defined in a `sockets` module here only for initial implementation purposes. It is imagined that in a finalized standard definition, the [=connect=] would be exposed as a global or within a [=binding object=]

+ A socket can be constructed using a connect method defined in a `sockets` module (early implementations may use `vendor:sockets` for the module name), or defined on a [=binding object=]. The connect method is the primary mechanism for creating a [=socket=] instance. It instantiates a socket with a resource identifier and some configuration values. It should synchronously return a socket instance in a pending state (or an error should be thrown). The socket will asynchronously connect depending on the implementation.