- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
- 26
- 27
- 28
- 29
- 30
- 31
- 32
- 33
- 34
- 35
- 36
- 37
- 38
- 39
- 40
import isMobileCall from 'ismobilejs';
type isMobileResult = {
apple: {
phone: boolean;
ipod: boolean;
tablet: boolean;
universal: boolean;
device: boolean;
};
amazon: {
phone: boolean;
tablet: boolean;
device: boolean;
};
android: {
phone: boolean;
tablet: boolean;
device: boolean;
};
windows: {
phone: boolean;
tablet: boolean;
device: boolean;
};
other: {
blackberry: boolean;
blackberry10: boolean;
opera: boolean;
firefox: boolean;
chrome: boolean;
device: boolean;
};
phone: boolean;
tablet: boolean;
any: boolean;
};
export const isMobile: isMobileResult = isMobileCall(globalThis.navigator);