LongRange

The LongRange dictionary is used to define a range of permitted integer values for a property, with either or both a maximum and minimum value specified. The ConstrainLongRange dictionary is based on this, augmenting it to support exact and ideal values as well.

Properties

max
A numeric value in the range of signed 32-bit integers, specifying the largest permissible value of the property it describes.
min
A numeric value in the range of signed 32-bit integers, specifying the smallest permissible value of the property it describes.

The specified min and/or and max values are required. If no match can be found that is within the given range, an error will occur.

Specifications

Specification Status Comment
Media Capture and Streams
The definition of 'LongRange' in that specification.
Candidate Recommendation Initial definition

Browser compatibility

Update compatibility data on GitHub
DesktopMobile
ChromeEdgeFirefoxInternet ExplorerOperaSafariAndroid webviewChrome for AndroidEdge MobileFirefox for AndroidOpera for AndroidiOS SafariSamsung Internet
Basic supportChrome Full support YesEdge ? Firefox Full support 50IE No support NoOpera Full support YesSafari ? WebView Android Full support YesChrome Android Full support YesEdge Mobile ? Firefox Android Full support 50Opera Android Full support YesSafari iOS ? Samsung Internet Android ?

Legend

Full support  
Full support
No support  
No support
Compatibility unknown  
Compatibility unknown

See also

Document Tags and Contributors

Contributors to this page: lucian95, Sheppy
Last updated by: lucian95,