Package Exports
- detectrtc
- detectrtc/DetectRTC
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (detectrtc) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
DetectRTC.js / Demo

A tiny JavaScript library that can be used to detect WebRTC features e.g. system having speakers, microphone or webcam, screen capturing is supported, number of audio/video devices etc.
It is MIT Licenced, which means that you can use it in any commercial/non-commercial product, free of cost.
npm install detectrtcTo use it:
<script src="./node_modules/detectrtc/DetectRTC.js"></script>Link the library
<script src="//cdn.webrtc-experiment.com/DetectRTC.js"></script>
How to use it?
<script src="//cdn.webrtc-experiment.com/DetectRTC.js"></script>List of available detections
DetectRTC.load(function() {
// DetectRTC.hasWebcam (has webcam device!)
// DetectRTC.hasMicrophone (has microphone device!)
// DetectRTC.hasSpeakers (has speakers!)
// DetectRTC.isScreenCapturingSupported
// DetectRTC.isSctpDataChannelsSupported
// DetectRTC.isRtpDataChannelsSupported
// DetectRTC.isAudioContextSupported
// DetectRTC.isWebRTCSupported
// DetectRTC.isDesktopCapturingSupported
// DetectRTC.isMobileDevice
// DetectRTC.isWebSocketsSupported
// DetectRTC.osName
// DetectRTC.browser.name
// DetectRTC.browser.version
// DetectRTC.browser.isChrome
// DetectRTC.browser.isFirefox
// DetectRTC.browser.isOpera
// DetectRTC.browser.isIE
// DetectRTC.browser.isSafari
// DetectRTC.DetectLocalIPAddress(callback)
});Why load method?
If you're not detecting audio/video input/outupt devices then you can skip this method.
DetectRTC.load simply makes sure that all devices are captured and valid result is set for relevant properties.
Demo
Credits
- Personal Webpage: http://www.muazkhan.com
- Email: muazkh@gmail.com
- Twitter: https://twitter.com/muazkh and https://twitter.com/WebRTCWeb
- Google+: https://plus.google.com/+WebRTC-Experiment
- Facebook: https://www.facebook.com/WebRTC
License
DetectRTC.js is released under MIT licence . Copyright (c) Muaz Khan.