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(v2): SSRBlock and SSRStream implementation #6181

Merged
merged 10 commits into from
May 4, 2024

Conversation

Varixo
Copy link
Member

@Varixo Varixo commented Apr 29, 2024

This PR adds support for the SSRBlock and SSRStream components

@Varixo Varixo marked this pull request as draft April 29, 2024 20:15
@@ -421,6 +421,10 @@ class SSRContainer extends _SharedContainer implements ISSRContainer {
this.write(rawHtml);
}

commentNode(text: string) {
this.write('<!--' + text + '-->');
Copy link
Contributor

Choose a reason for hiding this comment

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

I think these comment nodes will confuse the current implementation of materializeFromVNodeData, so we will need to update that.

Copy link
Member Author

Choose a reason for hiding this comment

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

It is already done by this code :D but I have added additional test for this

      while (!isElement(child)) {
        child = child!.nextSibling;
        if (!child) {
          throwErrorAndStop(
            'Materialize error: missing element: ' + vData + ' ' + peek() + ' ' + nextToConsumeIdx
          );
        }
      }

@Varixo Varixo marked this pull request as ready for review May 2, 2024 08:21
@mhevery mhevery merged commit 370a536 into QwikDev:build/v2 May 4, 2024
14 of 18 checks passed
@Varixo Varixo deleted the build/v2-streaming branch May 4, 2024 07:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants