Skip to content
This repository was archived by the owner on Apr 6, 2023. It is now read-only.
/frameworkPublic archive

fix(nuxt): fix lazy import of .client components - #7422

Merged
atinux merged 7 commits into
nuxt:mainfrom
huang-julien:fix/lazy.client
Oct 3, 2022
Merged

fix(nuxt): fix lazy import of .client components#7422
atinux merged 7 commits into
nuxt:mainfrom
huang-julien:fix/lazy.client

Conversation

@huang-julien

Copy link
Copy Markdown
Member

🔗 Linked issue

resolvenuxt/nuxt#14868

❓ Type of change

  • 📖 Documentation (updates to the documentation or readme)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • 👌 Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

📚 Description

Hi 👋 , this PR change the component loader to wrap the lazy loaded component instead of wrapping the async component. Wrapping the async component with createClientOnly prevent the component from being mounted.

📝 Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

@netlify

netlifyBot commented Sep 11, 2022

Copy link
Copy Markdown

Deploy Preview for nuxt3-docs canceled.

NameLink
🔨 Latest commitef3833d
🔍 Latest deploy loghttps://app.netlify.com/sites/nuxt3-docs/deploys/6329d4e3a2ed210009086705

@huang-julien
huang-julien marked this pull request as draft September 11, 2022 21:20
@huang-julien
huang-julien marked this pull request as ready for review September 11, 2022 21:32
@pi0
pi0 requested review from antfu and danielroeSeptember 12, 2022 08:33
@pi0
pi0force-pushed the main branch 2 times, most recently from 247e18b to c98e5c7CompareSeptember 14, 2022 10:41
@atinux
atinux merged commit 2c8c212 into nuxt:mainOct 3, 2022
@danielroedanielroe mentioned this pull request Oct 9, 2022
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Lazy .client components are not mounted or cause hydration issues

3 participants

@huang-julien@atinux@danielroe