You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If a component author does something like the following:
import{LightningElement}from'lwc';consttmpl=undefined;constgenerateMarkup=undefined;exportdefaultclassextendsLightningElement{connectedCallback(){// just use the variables to avoid them being tree-shakenObject.assign({},{
tmpl,
generateMarkup
});}}
Then currently, it will throw an error at compile time in the @lwc/ssr-compiler:
Identifier "tmpl" has already been declared
Identifier "generateMarkup" has already been declared
These are pretty generic names, so we should probably switch to something like __lwcTemplate and __lwcGenerateMarkup to avoid collisions.
If a component author does something like the following:
Then currently, it will throw an error at compile time in the
@lwc/ssr-compiler
:These are pretty generic names, so we should probably switch to something like
__lwcTemplate
and__lwcGenerateMarkup
to avoid collisions.Related:
generateMarkup
#4768The text was updated successfully, but these errors were encountered: