mirror of
https://github.com/elk-zone/elk.git
synced 2024-11-19 07:19:58 +00:00
fix: scrollToTop does not work as expected (#271)
This commit is contained in:
parent
2b46bd5a15
commit
e3ab850cc1
1 changed files with 1 additions and 1 deletions
|
@ -2,7 +2,7 @@ export default defineNuxtPlugin(() => {
|
||||||
return {
|
return {
|
||||||
provide: {
|
provide: {
|
||||||
scrollToTop: () => {
|
scrollToTop: () => {
|
||||||
document.body.scrollTo(0, 0)
|
window.scrollTo({ top: 0, left: 0, behavior: 'smooth' })
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue