You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hook to use [MediaDevices](https://developer.mozilla.org/en-US/docs/Web/API/MediaDevices) interface methods, that give access to any hardware source of media data.
it is a string that identifies which method to return as a result. It can be _devicesList_, _supportedConstraintsList_, _DisplayCapture_, or _mediaInputCapture_.
67
+
>
68
+
69
+
> ### Returns
70
+
>
71
+
> __result__: _UseMediaDevicesResult_
72
+
> if __action__ is:
73
+
> -_devicesList_: so _result_ is __enumeratedDevices__ method of MediaDevices interface.
74
+
> -_supportedConstraintsList_: so _result_ is __getSupportedConstraints__ method of MediaDevices interface.
75
+
> -_DisplayCapture_: so _result_ is __getDisplayMedia__ method of MediaDevices interface.
76
+
> -_mediaInputCapture_: so _result_ is __getUserMedia__ method of MediaDevices interface.
Hook to query the status of API permissions attributed to the current context. Refer to [PermissionAPI](https://developer.mozilla.org/en-US/docs/Web/API/Permissions_API).
* **`useMediaDevices`**: Hook to use [MediaDevices](https://developer.mozilla.org/en-US/docs/Web/API/MediaDevices) interface methods, that give access to any hardware source of media data.
10
+
* @param {UseMediaDevicesProps} action - it is a string that identifies which method to return as a result. It can be _devicesList_, _supportedConstraintsList_, _DisplayCapture_, or _mediaInputCapture_.
11
+
* @returns {UseMediaDevicesResult} result - the function returned by __action__ parameter value.
12
+
* if __action__ is:
13
+
* - _devicesList_: so _result_ is __enumeratedDevices__ method of MediaDevices interface.
14
+
* - _supportedConstraintsList_: so _result_ is __getSupportedConstraints__ method of MediaDevices interface.
15
+
* - _DisplayCapture_: so _result_ is __getDisplayMedia__ method of MediaDevices interface.
16
+
* - _mediaInputCapture_: so _result_ is __getUserMedia__ method of MediaDevices interface.
0 commit comments