chore(cli): scroll to anchor immediately (#6323)

This commit is contained in:
neverland
2020-05-20 17:25:22 +08:00
committed by GitHub
parent dad0160bb4
commit 1f117ab723

View File

@@ -4,9 +4,7 @@ export function scrollToAnchor(selector) {
const timer = setInterval(() => { const timer = setInterval(() => {
const el = document.querySelector(selector); const el = document.querySelector(selector);
if (el) { if (el) {
el.scrollIntoView({ el.scrollIntoView();
behavior: 'smooth',
});
clearInterval(timer); clearInterval(timer);
} else { } else {
count++; count++;