angular中解决:
ngAfterViewInit(): void {
document.body.addEventListener(‘focusout‘, function () {
window.scrollTo(0, 0);
document.body.scrollIntoView();
document.documentElement.scrollIntoView();
});
}
|
2022-06-08 02:42:53
angular中解决:
ngAfterViewInit(): void {
document.body.addEventListener(‘focusout‘, function () {
window.scrollTo(0, 0);
document.body.scrollIntoView();
document.documentElement.scrollIntoView();
});
}
|