Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(nuxt): allow 'lazy' (non-blocking) server components #21918

Merged
merged 6 commits into from Jul 31, 2023

Conversation

danielroe
Copy link
Member

@danielroe danielroe commented Jul 3, 2023

πŸ”— Linked issue

❓ Type of change

  • πŸ“– Documentation (updates to the documentation, readme or JSdoc annotations)
  • 🐞 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)
  • 🧹 Chore (updates to the build process or auxiliary tools and libraries)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

πŸ“š Description

This adds support for 'lazy' server components that don't block navigation on the client-side, which is particularly useful when a server component might take a long time to render something and we want to show a loading state.

It adds support for a fallback slot (to display while a component is rendering) and a lazy prop. It would be nice to come up with a way for server components to have type support for slot/prop. πŸ€”

TODO:

  • ensure lazy type works
  • add support for fallback slot when component is loading

πŸ“ Checklist

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

@danielroe danielroe marked this pull request as ready for review July 30, 2023 23:09
Copy link
Member

@huang-julien huang-julien left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

πŸ‘ ❀️

@danielroe danielroe merged commit 5926bbe into main Jul 31, 2023
29 checks passed
@danielroe danielroe deleted the feat/lazy-server-components branch July 31, 2023 08:51
@github-actions github-actions bot mentioned this pull request Jul 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants