File tree 1 file changed +5
-1
lines changed
1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -554,7 +554,9 @@ only removes listeners added with
554
554
### websocket.send(data[ , options] [ , callback ] )
555
555
556
556
- ` data ` {Array|Number|Object|String|ArrayBuffer|Buffer|DataView|TypedArray} The
557
- data to send.
557
+ data to send. ` Object ` values are only supported if they conform to the
558
+ requirements of [ ` Buffer.from() ` ] [ ] . If those constraints are not met, a
559
+ ` TypeError ` is thrown.
558
560
- ` options ` {Object}
559
561
- ` binary ` {Boolean} Specifies whether ` data ` should be sent as a binary or
560
562
not. Default is autodetected.
@@ -656,6 +658,8 @@ as configured by the `maxPayload` option.
656
658
[ concurrency-limit ] : https://github.com/websockets/ws/issues/1202
657
659
[ duplex-options] :
658
660
https://nodejs.org/api/stream.html#stream_new_stream_duplex_options
661
+ [ ` buffer.from() ` ] :
662
+ https://nodejs.org/api/buffer.html#static-method-bufferfromobject-offsetorencoding-length
659
663
[ ` http.request() ` ] :
660
664
https://nodejs.org/api/http.html#http_http_request_options_callback
661
665
[ ` https.request() ` ] :
You can’t perform that action at this time.
0 commit comments