Skip to content

Commit eda25fe

Browse files
committed
add feature detection example
fixes #1. Bullet 0 is ok because it is preliminary :-)
1 parent 92579b7 commit eda25fe

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

explainer.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,12 @@ iterations to support additional use cases such as:
4343
* Custom codecs for special purposes (in combination with WebCodecs)
4444

4545
## Code Examples
46+
0. Feature detection can be done as follows:
47+
48+
<pre>
49+
const supportsInsertableStreams = window.RTCRtpSender &&
50+
!!RTCRtpSender.prototype.createEncodedVideoStreams;
51+
</pre>
4652

4753
1. Let an PeerConnection know that it should allow exposing the data flowing through it
4854
as streams.

0 commit comments

Comments
 (0)