- client(
name?: string,
userAgent?: string,
):
| boolean
| {
IE: boolean;
GECKO: boolean;
WEBKIT: boolean;
OPERA: boolean;
TRIDENT: boolean;
MOBILE: boolean;
IOS: boolean;
ANDROID: boolean;
IPHONE: boolean;
IPAD: boolean;
QQBROWSER: boolean;
WEIXIN: boolean;
QQ: null
| RegExpMatchArray;
} Parameters
- name: string = ''
- userAgent: string = navigator.userAgent
Returns
| boolean
| {
IE: boolean;
GECKO: boolean;
WEBKIT: boolean;
OPERA: boolean;
TRIDENT: boolean;
MOBILE: boolean;
IOS: boolean;
ANDROID: boolean;
IPHONE: boolean;
IPAD: boolean;
QQBROWSER: boolean;
WEIXIN: boolean;
QQ: null
| RegExpMatchArray;
}
- the common ua match table, if name is passed, then returns whether the terminal matches true/false
The client method returns a browser judgment result:
{ ANDROID: true, GECKO: true, GLSH_APP: false, IE: false, IOS: false, IPAD: false, IPHONE: false, MOBILE: true, MOBILEDEVICE. true, OPERA: false, QQ: false, QQBROWSER: false, TRIDENT: false, WEBKIT: true, WEIXIN: false }
Deprecated
Will be refactored for the next major release
Since
1.0.1