Add comment for browser and platform detection
This commit is contained in:
parent
c32d4f3cd0
commit
11ae8f0ef4
|
@ -79,6 +79,13 @@ try {
|
||||||
}
|
}
|
||||||
export const hasScrollbarGutter = _hasScrollbarGutter;
|
export const hasScrollbarGutter = _hasScrollbarGutter;
|
||||||
|
|
||||||
|
/*
|
||||||
|
* The functions for detection of platforms and browsers below are exported
|
||||||
|
* but the use of these should be minimized as much as possible.
|
||||||
|
*
|
||||||
|
* It's better to use feature detection than platform detection.
|
||||||
|
*/
|
||||||
|
|
||||||
export function isMac() {
|
export function isMac() {
|
||||||
return navigator && !!(/mac/i).exec(navigator.platform);
|
return navigator && !!(/mac/i).exec(navigator.platform);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue