-
Notifications
You must be signed in to change notification settings - Fork 400
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(engine): render() can only return qualifying templates #764
Conversation
Benchmark resultsBase commit: lwc-engine-benchmark
|
@@ -35,6 +37,7 @@ describe('patch', () => { | |||
class MyComponent extends LightningElement { | |||
renderedCallback() { | |||
flag = true; | |||
return emptyTemplate; |
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.
Why does renderedCallback
need to return this?
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.
uff, my bad!
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.
Removed
@caridy do another empty commit to double check the numbers are not as odd. |
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.
Changes look good but we'll need to exercise caution when releasing this.
Benchmark resultsBase commit: lwc-engine-benchmark
|
@diervo not sure how to justify that regression, this PR removes two conditions in prod mode. It should be faster :), and it is not about wc, but for any rendering process. |
@diervo We need to hold off on this one until after LGC finishes their long-awaited release. This change also needs to go in with 16867957. |
The necessary downstream changes have been made but we probably want to release this separately from the big CSS changes since it's always possible (though unlikely) that someone added a new render method that returns |
ready to roll |
Details
Previously, we supported render() to return undefined or qualifying template. With this PR, we will enforce that if there is a render method, it should return a qualifying template.
Does this PR introduce a breaking change?