Version
module: 2.0.0
nuxt: 4.1.3
Nuxt configuration
sanity: {
projectId: process.env.NUXT_SANITY_PROJECT_ID,
dataset: process.env.NUXT_SANITY_DATASET,
apiVersion: process.env.NUXT_SANITY_API_VERSION || "2025-10-20",
token: process.env.NUXT_SANITY_API_READ_TOKEN, // Only required when using a private dataset
visualEditing: {
token: process.env.NUXT_SANITY_API_READ_TOKEN,
studioUrl: process.env.NUXT_SANITY_STUDIO_URL,
stega: true,
zIndex: 51,
},
},
What is expected?
Scroll position remains after HMR.
What is actually happening?
Scroll position resets every time I change my .vue file.
Steps to reproduce
Additional information
Checklist
Steps to reproduce
Use useSanityQuery. Even if result is never read, every change to the containing .vue file will lose the scroll position.
What is expected?
Scroll position remains stable.
What is actually happening?
Scroll position resets to top of page.
Version
module: 2.0.0
nuxt: 4.1.3
Nuxt configuration
What is expected?
Scroll position remains after HMR.
What is actually happening?
Scroll position resets every time I change my .vue file.
Steps to reproduce
Additional information
Checklist
Steps to reproduce
Use
useSanityQuery. Even if result is never read, every change to the containing .vue file will lose the scroll position.What is expected?
Scroll position remains stable.
What is actually happening?
Scroll position resets to top of page.