Skip to content

Commit

Permalink
Update index.bs
Browse files Browse the repository at this point in the history
  • Loading branch information
jasnell authored Nov 5, 2023
1 parent 36a14ba commit 226f2fb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -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/, [email protected]
Editor: Ethan Arrowood, Vercel https://vercel.com/, [email protected]
Editor: James M Snell, Cloudflare https://cloudflare.com/, [email protected]
Abstract: Sockets API for Non-Browser EcmaScript-based runtimes.
Markup Shorthands: markdown yes
Markup Shorthands: idl yes
Expand Down Expand Up @@ -42,6 +43,8 @@ A socket becomes <i>closed</i> when its {{close()}} method is called. A socket c

<h3 id="connect-concept-section">Connect</h3>

<p class="note">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=]</p>

A socket can be constructed using a <dfn export id="connect-concept">connect</dfn> 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 <i>pending</i> state (or an error should be thrown). The socket will asynchronously <i>connect</i> depending on the implementation.
Expand Down

0 comments on commit 226f2fb

Please sign in to comment.