-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
fix(container): emit components as partials #12239
Conversation
🦋 Changeset detectedLatest commit: e796f9f The changes in this PR will be included in the next version bump. Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
.changeset/soft-rabbits-draw.md
Outdated
|
||
Until now, the Container API was rendering the components as they were full-fledged Astro pages. | ||
|
||
Full-fledged Astro pages contain `<!DOCTYPE html>` but default. This was not intended, and this patch fixes the behavior. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My take is still that we shouldn't be adding the doctype for people 😠
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just some suggestions for your consideration, @ematipico ! 🙌
Co-authored-by: Sarah Rainsberger <[email protected]>
Changes
The container API was rendering components as full-fledged pages, which was a bug.
This PR ships a breaking change to the rendered default behaviour of the container API. Now, the components are rendered as partials by default, and users can tweak the behaviour by passing
partial: false
as a new optionTesting
Added new assertions a new test case
Docs
withastro/docs#9696