`rc.5` breaks hydrating payload data on Netlify/Vercel
See original GitHub issueEnvironment
- 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
-
Since this seems to be specific to deployment on Vercel/Netlify, here a reproduction: 👉 Live demonstration of the bug
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 theuseFetch
runs directly inapp.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:
- Created a year ago
- Reactions:5
- Comments:13 (6 by maintainers)
Top 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 >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
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.
With the workaround from https://github.com/nuxt/framework/issues/6204#issuecomment-1201398080 this issue is resolved temporarily. 🎉