This is an experimental technologyCheck the Browser compatibility table carefully before using this in production.
Draft This page is not complete.
The RTCDataChannel.onclosing
property is an EventHandler
which specifies a function to be called by the browser when the closing
event is received by the RTCDataChannel
. This is a simple Event
which indicates that the data channel is being closed, that is, RTCDataChannel
transitions to "closing" state. For example, after RTCDataChannel.close()
was called but the underlying data transport might not have been closed yet.
Syntax
RTCDataChannel.onclosing = function;
Value
A function which the browser will call to handle the closing
event. The function receives as its sole input parameter the event itself, as an object of type Event
.
Specifications
Specification | Status | Comment |
---|---|---|
WebRTC 1.0: Real-time Communication Between BrowsersThe definition of 'RTCDataChannel.onclosing' in that specification. | Candidate Recommendation | Initial specification. |
Browser compatibility
The compatibility table on this page is generated from structured data. If you'd like to contribute to the data, please check out https://github.com/mdn/browser-compat-data and send us a pull request.
Update compatibility data on GitHub
Desktop | Mobile | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Chrome
Full support 81 |
Edge
Full support 81 |
Firefox
No support No |
IE
No support No |
Opera
Full support 68 |
Safari
No support No |
WebView Android
Full support 81 |
Chrome Android
Full support 81 |
Firefox Android
No support No |
Opera Android
? |
Safari iOS
No support No |
Samsung Internet Android
Full support 13.0 |
Legend
- Full support
- Full support
- No support
- No support
- Compatibility unknown
- Compatibility unknown
- Experimental. Expect behavior to change in the future.'
- Experimental. Expect behavior to change in the future.
See also
- WebRTC
RTCDataChannel.onclose
event handler and itsclose
event.RTCDataChannel.onopen
- The
open
event and its type,Event
.
RTCDataChannel.onclosing by Mozilla Contributors is licensed under CC-BY-SA 2.5.