Skip to content

Commit 0210e74

Browse files
committed
fix IE9 regression (fix #1104)
1 parent 078ad83 commit 0210e74

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/history/html5.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@ import {
1414
} from '../util/scroll-position'
1515

1616
// use User Timing api (if present) for more accurate key precision
17-
const Time = inBrowser ? (window.performance || Date) : Date
17+
const Time = inBrowser && window.performance && window.performance.now
18+
? window.performance
19+
: Date
1820

1921
const genKey = () => String(Time.now())
2022
let _key: string = genKey()

0 commit comments

Comments
 (0)