UNPKG
@better-scroll/shared-utils
Version:
latest (2.5.1)
next (2.0.0-beta.10)
2.5.1
2.5.0
2.4.2
2.4.1
2.4.0
2.3.1
2.3.0
2.2.1
2.2.0
2.1.4
2.1.3
2.1.2
2.1.1
2.1.0
2.0.7
2.0.6
2.0.5
2.0.4
2.0.3
2.0.2
2.0.1
2.0.0
2.0.0-beta.10
2.0.0-beta.9
2.0.0-beta.8
2.0.0-beta.6
2.0.0-beta.5
2.0.0-beta.4
2.0.0-beta.2
2.0.0-beta.1
2.0.0-alpha.20
2.0.0-alpha.19
2.0.0-alpha.18
2.0.0-alpha.16
2.0.0-alpha.15
2.0.0-alpha.14
2.0.0-alpha.13
2.0.0-alpha.12
2.0.0-alpha.11
2.0.0-alpha.10
2.0.0-alpha.9
2.0.0-alpha.7
2.0.0-alpha.5
2.0.0-alpha.4
shared-utils for BetterScroll
github.com/ustbhuangyi/better-scroll
ustbhuangyi/better-scroll
@better-scroll/shared-utils
/
src
/
debug.ts
10 lines
(8 loc)
•
214 B
text/typescript
View Raw
1
2
3
4
5
6
7
8
9
10
export
function
warn
(
msg
:
string
) {
console
.
error
(
`[BScroll warn]:
${msg}
`
) }
export
function
assert
(
condition
:
string
|
boolean
,
msg
:
string
) {
if
(!condition) {
throw
new
Error
(
'[BScroll] '
+ msg) } }