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

fix(v2): fix vnode separators #6596

Merged
merged 3 commits into from
Jun 25, 2024
Merged

Conversation

Varixo
Copy link
Member

@Varixo Varixo commented Jun 24, 2024

This PR fixes vnode separators and missing refElement error in the docs

@Varixo Varixo requested a review from a team as a code owner June 24, 2024 16:45
@@ -956,7 +956,7 @@ class SSRContainer extends _SharedContainer implements ISSRContainer {
let skipCount = elementIdx - lastSerializedIdx;
// console.log('emitVNodeSeparators', lastSerializedIdx, elementIdx, skipCount);
while (skipCount != 0) {
if (skipCount >= 4096) {
Copy link
Member Author

@Varixo Varixo Jun 24, 2024

Choose a reason for hiding this comment

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

@mhevery I think this is a good change. If skipCount is equal to 4096 then we want to execute code in the else block, right?

Copy link
Contributor

Choose a reason for hiding this comment

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

yes, that is correct. Thank you for noticing.

Comment on lines 37 to 40
ADVANCE_2048_CH: /* * */ ',', // ',' is vNodeData separator skipping 1024.
ADVANCE_2048: /* ****** */ 44, // ',' is vNodeData separator skipping 1024.
ADVANCE_4096_CH: /* * */ `.`, // `.` is vNodeData separator skipping 2048.
ADVANCE_4096: /* ****** */ 46, // `.` is vNodeData separator skipping 2048.
Copy link
Member Author

Choose a reason for hiding this comment

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

I don't know why we are missing the 45 charcode?

Copy link
Contributor

Choose a reason for hiding this comment

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

That is weird! I don't think we should be skipping anything. I think that is a bug and should be fixed.

Comment on lines 37 to 40
ADVANCE_2048_CH: /* * */ ',', // ',' is vNodeData separator skipping 1024.
ADVANCE_2048: /* ****** */ 44, // ',' is vNodeData separator skipping 1024.
ADVANCE_4096_CH: /* * */ `.`, // `.` is vNodeData separator skipping 2048.
ADVANCE_4096: /* ****** */ 46, // `.` is vNodeData separator skipping 2048.
Copy link
Contributor

Choose a reason for hiding this comment

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

That is weird! I don't think we should be skipping anything. I think that is a bug and should be fixed.

@@ -956,7 +956,7 @@ class SSRContainer extends _SharedContainer implements ISSRContainer {
let skipCount = elementIdx - lastSerializedIdx;
// console.log('emitVNodeSeparators', lastSerializedIdx, elementIdx, skipCount);
while (skipCount != 0) {
if (skipCount >= 4096) {
Copy link
Contributor

Choose a reason for hiding this comment

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

yes, that is correct. Thank you for noticing.

@Varixo Varixo merged commit a223f6b into QwikDev:build/v2 Jun 25, 2024
18 checks passed
@Varixo Varixo deleted the v2-fix-vnode-separators branch June 25, 2024 15:07
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.

None yet

2 participants