UNPKG
js-wrench
Version:
latest (1.3.1)
1.3.1
1.3.0
1.2.2
1.2.1
JS函数库
js-wrench
/
modules
/
isiPad.ts
15 lines
(14 loc)
•
315 B
text/typescript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
/** *
@description
是否iPad * *
@return
{
*
} {
boolean
} 返回一个布尔值 *
@example
isiPad() => true|false */
const
isiPad = ():
boolean
=>
{
let
userAgentInfo
:
string
= navigator.
userAgent
if
(userAgentInfo.
indexOf
(
'iPad'
) > -
1
) {
return
true
}
return
false
}
export
default
isiPad