N
Nuxt2y ago
Likonima

[Nuxt 3 - router] keeps y position

Im struggling to fix nuxt and router. it sticks to current y pos on routing, even though i added
// router.options.ts
import type { RouterConfig } from '@nuxt/schema'
export default <RouterConfig>{
scrollBehavior () {
return { top: 0 }
}
}
// router.options.ts
import type { RouterConfig } from '@nuxt/schema'
export default <RouterConfig>{
scrollBehavior () {
return { top: 0 }
}
}
2 Replies
Likonima
LikonimaOP2y ago
Would anyone know how this is possible. i did follow like 5 gh issues that were all closed since this should be the default behaviour
conner
conner2y ago
Hey @Likonima, can you maybe build a small reproduction repository?
Want results from more Discord servers?
Add your server