question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`rc.5` breaks hydrating payload data on Netlify/Vercel

See original GitHub issue

Environment

  • Operating System: Darwin
  • Node Version: v16.15.0
  • Nuxt Version: 3.0.0-rc.5
  • Package Manager: pnpm@7.5.1
  • Builder: vite
  • User Config: vite
  • Runtime Modules: -
  • Build Modules: -

Reproduction

Describe the bug

Preamble

Source of the bug is the same to https://github.com/nuxt/framework/issues/5895. It does not origin in a missing unique key from the useFetch composable. A key is provided.

The Bug Itself

On Netlify the server-rendered Nuxt instance fetches custom data, but doesn’t write it to the nuxt.payload.data key or even renders the page’s template correctly.

Thus, the useFetch request runs again when the client loaded.

Additional context

  • It seems to work when no pages is present and the useFetch runs directly in app.vue. Does the bug originate in https://github.com/nuxt/framework/pull/5709 maybe?
  • It seems like a problem specific to Netlify. If I pnpm run build locally and serve the app, it is working.

Logs

No response

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:5
  • Comments:13 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
pi0commented, Aug 8, 2022

Thanks for confirmation. Using nuxt edge and (soon upcoming) rc.7 you no longer need a workaround and deployments should start working out of the box.

2reactions
johannschopplichcommented, Aug 2, 2022

With the workaround from https://github.com/nuxt/framework/issues/6204#issuecomment-1201398080 this issue is resolved temporarily. 🎉

Read more comments on GitHub >

github_iconTop Results From Across the Web

Migrate to Vercel from Netlify
1. Netlify UI Environment Data ... Open your project in Netlify and find the Site Settings . ... Select Build and Deploy from...
Read more >
How to Build eCommerce Stores on Netlify with Commerce.js ...
Step 3: Seed the data necessary to power your Chec store and start your ... Actions are object payloads that require a unique...
Read more >
Vercel vs. Netlify: Jamstack Deployment Comparison - Snipcart
Understand the differences between Vercel vs. Netlify as deployment & hosting solutions for your Jamstack projects in 2021.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found