nuxt-modules / nuxt-modules/sanity

Hydration issue with Buttons/Marks inside ListComponents

Open
#649 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug needs-repro
Dominant language
TypeScript
Stars
265
Forks
43
Avg merge
11h
Merged PRs (30d)
18

Description

Not sure this is a bug with Sanity but rather my own Nuxt setup. Any help would be appreciated!

Version

module: 1.6.0
nuxt: 3.1.1
srr: true & false

  components: {
    global: true,
    loader: true,
    dirs: ['~/components'],
  },
What is expected?

ListComponent renders Marks on both SSR and Client Side

image
image

What is actually happening?

ListComponent only renders Marks when loading page directly, not when browsing between pages
image
image

Things I've tried

Importing serializers directly using both import and resolveComponent - asynchronous component does not seem to affect the rendering/hydration

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the issue with Nuxt 3.1.1, SSR enabled and disabled, comparing direct page loads with client-side navigation. Check how ListComponents render Buttons and Marks in each path; done means Marks render consistently during both SSR hydration and client-side navigation.

Written by the indexing model from the issue text.

Assessment

Tech stack
nuxt, typescript
Domain
frontend, web-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.