Skip to content

Commit d68117b

Browse files
committed
Move duplex over to RequestInit as a var
1 parent 87f489f commit d68117b

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

dom/src/main/scala/org/scalajs/dom/Request.scala

-5
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,4 @@ class Request(input: RequestInfo, init: RequestInit = null) extends Body {
4747
def keepalive: Boolean = js.native
4848

4949
def signal: AbortSignal = js.native
50-
51-
/** "half" is the only valid value and it is for initiating a half-duplex fetch (i.e., the user agent sends the entire
52-
* request before processing the response).
53-
*/
54-
def duplex: RequestDuplex = js.native
5550
}

dom/src/main/scala/org/scalajs/dom/RequestInit.scala

+5
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,11 @@ trait RequestInit extends js.Object {
3030

3131
var signal: js.UndefOr[AbortSignal] = js.undefined
3232

33+
/** "half" is the only valid value and it is for initiating a half-duplex fetch (i.e., the user agent sends the entire
34+
* request before processing the response).
35+
*/
36+
var duplex: js.UndefOr[RequestDuplex] = js.undefined
37+
3338
/** The whatwg spec section on [[https://fetch.spec.whatwg.org/#requestinit RequestInit dictionary]] has a comment
3439
* that states that this value "can only be set to null". In the detailed steps section for
3540
* [[https://fetch.spec.whatwg.org/#dom-request the Request(input,init) constructor]] it says even more clearly: "If

0 commit comments

Comments
 (0)