-
Notifications
You must be signed in to change notification settings - Fork 405
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(ssr): implement fixes for known issues #5188
Conversation
@@ -9,5 +9,6 @@ export default class GetterClassList extends LightningElement { | |||
classList.remove('b'); | |||
|
|||
expect(this.getAttribute('class')).toBe('a c d-e'); | |||
expect(() => this.classList.length).not.toThrow(); |
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.
expect(() => this.classList.length).not.toThrow(); | |
expect(this.classList.length).toBe(3); |
We know what it should be, why not check that directly?
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.
I had that originally. Original SSR implementation returns undefined
. When we retire @lwc/engine-server
, we may want to revisit things like this.
@@ -0,0 +1,4 @@ | |||
<template> | |||
Value: {foo.value} | |||
<!-- Dude --> |
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.
@@ -215,7 +215,13 @@ const visitors: Visitors = { | |||
break; | |||
} | |||
}, | |||
Super(path, _state) { | |||
Super(path, state) { |
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.
Does this visitor also apply to super.method()
calls in other methods?
@@ -215,7 +215,13 @@ const visitors: Visitors = { | |||
break; | |||
} | |||
}, | |||
Super(path, _state) { | |||
Super(path, state) { |
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.
aside: we should validate whether the other visitors need this guard #5189.
Details
As we've rendered some internal components under the new SSR implementation, a handful of issues were identified. This PR introduces corresponding test cases and fixes.
Does this pull request introduce a breaking change?
Does this pull request introduce an observable change?
Further closes the gap between SSRv1 and SSRv2.
GUS work item
W-17740271