@lwc/template-compiler 8.19.0 → 8.20.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs.js +3 -8
- package/dist/index.js +3 -8
- package/package.json +3 -3
package/dist/index.cjs.js
CHANGED
|
@@ -13472,11 +13472,6 @@ function bindAttributeExpression(attr, element, codeGen, addLegacySanitizationHo
|
|
|
13472
13472
|
* SPDX-License-Identifier: MIT
|
|
13473
13473
|
* For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
|
|
13474
13474
|
*/
|
|
13475
|
-
// structuredClone is only available in Node 17+
|
|
13476
|
-
// https://developer.mozilla.org/en-US/docs/Web/API/structuredClone#browser_compatibility
|
|
13477
|
-
const doStructuredClone = typeof structuredClone === 'function'
|
|
13478
|
-
? structuredClone
|
|
13479
|
-
: (obj) => JSON.parse(JSON.stringify(obj));
|
|
13480
13475
|
const RENDER_APIS = {
|
|
13481
13476
|
bind: { name: 'b', alias: 'api_bind' },
|
|
13482
13477
|
comment: { name: 'co', alias: 'api_comment' },
|
|
@@ -13826,7 +13821,7 @@ class CodeGen {
|
|
|
13826
13821
|
if (this.state.config.experimentalComplexExpressions) {
|
|
13827
13822
|
// Cloning here is necessary because `this.replace()` is destructive, and we might use the
|
|
13828
13823
|
// node later during static content optimization
|
|
13829
|
-
expression =
|
|
13824
|
+
expression = structuredClone(expression);
|
|
13830
13825
|
return bindComplexExpression(expression, this);
|
|
13831
13826
|
}
|
|
13832
13827
|
// We need access to both this `this` and the walker's `this` in the walker
|
|
@@ -13834,7 +13829,7 @@ class CodeGen {
|
|
|
13834
13829
|
const scope = this;
|
|
13835
13830
|
// Cloning here is necessary because `this.replace()` is destructive, and we might use the
|
|
13836
13831
|
// node later during static content optimization
|
|
13837
|
-
expression =
|
|
13832
|
+
expression = structuredClone(expression);
|
|
13838
13833
|
// TODO [#3370]: when the template expression flag is removed, the
|
|
13839
13834
|
// ComplexExpression type should be redefined as an ESTree Node. Doing
|
|
13840
13835
|
// so when the flag is still in place results in a cascade of required
|
|
@@ -14768,5 +14763,5 @@ exports.generateScopeTokens = generateScopeTokens;
|
|
|
14768
14763
|
exports.kebabcaseToCamelcase = kebabcaseToCamelcase;
|
|
14769
14764
|
exports.parse = parse;
|
|
14770
14765
|
exports.toPropertyName = toPropertyName;
|
|
14771
|
-
/** version: 8.
|
|
14766
|
+
/** version: 8.20.0 */
|
|
14772
14767
|
//# sourceMappingURL=index.cjs.js.map
|
package/dist/index.js
CHANGED
|
@@ -13448,11 +13448,6 @@ function bindAttributeExpression(attr, element, codeGen, addLegacySanitizationHo
|
|
|
13448
13448
|
* SPDX-License-Identifier: MIT
|
|
13449
13449
|
* For full license text, see the LICENSE file in the repo root or https://opensource.org/licenses/MIT
|
|
13450
13450
|
*/
|
|
13451
|
-
// structuredClone is only available in Node 17+
|
|
13452
|
-
// https://developer.mozilla.org/en-US/docs/Web/API/structuredClone#browser_compatibility
|
|
13453
|
-
const doStructuredClone = typeof structuredClone === 'function'
|
|
13454
|
-
? structuredClone
|
|
13455
|
-
: (obj) => JSON.parse(JSON.stringify(obj));
|
|
13456
13451
|
const RENDER_APIS = {
|
|
13457
13452
|
bind: { name: 'b', alias: 'api_bind' },
|
|
13458
13453
|
comment: { name: 'co', alias: 'api_comment' },
|
|
@@ -13802,7 +13797,7 @@ class CodeGen {
|
|
|
13802
13797
|
if (this.state.config.experimentalComplexExpressions) {
|
|
13803
13798
|
// Cloning here is necessary because `this.replace()` is destructive, and we might use the
|
|
13804
13799
|
// node later during static content optimization
|
|
13805
|
-
expression =
|
|
13800
|
+
expression = structuredClone(expression);
|
|
13806
13801
|
return bindComplexExpression(expression, this);
|
|
13807
13802
|
}
|
|
13808
13803
|
// We need access to both this `this` and the walker's `this` in the walker
|
|
@@ -13810,7 +13805,7 @@ class CodeGen {
|
|
|
13810
13805
|
const scope = this;
|
|
13811
13806
|
// Cloning here is necessary because `this.replace()` is destructive, and we might use the
|
|
13812
13807
|
// node later during static content optimization
|
|
13813
|
-
expression =
|
|
13808
|
+
expression = structuredClone(expression);
|
|
13814
13809
|
// TODO [#3370]: when the template expression flag is removed, the
|
|
13815
13810
|
// ComplexExpression type should be redefined as an ESTree Node. Doing
|
|
13816
13811
|
// so when the flag is still in place results in a cascade of required
|
|
@@ -14739,5 +14734,5 @@ function compile(source, filename, config) {
|
|
|
14739
14734
|
}
|
|
14740
14735
|
|
|
14741
14736
|
export { ElementDirectiveName, LWCDirectiveDomMode, LWCDirectiveRenderMode, LwcTagName, RootDirectiveName, TemplateDirectiveName, compile, compile as default, generateScopeTokens, kebabcaseToCamelcase, parse, toPropertyName };
|
|
14742
|
-
/** version: 8.
|
|
14737
|
+
/** version: 8.20.0 */
|
|
14743
14738
|
//# sourceMappingURL=index.js.map
|
package/package.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"You can safely modify dependencies, devDependencies, keywords, etc., but other props will be overwritten."
|
|
5
5
|
],
|
|
6
6
|
"name": "@lwc/template-compiler",
|
|
7
|
-
"version": "8.
|
|
7
|
+
"version": "8.20.0",
|
|
8
8
|
"description": "Template compiler package",
|
|
9
9
|
"keywords": [
|
|
10
10
|
"lwc"
|
|
@@ -46,8 +46,8 @@
|
|
|
46
46
|
}
|
|
47
47
|
},
|
|
48
48
|
"dependencies": {
|
|
49
|
-
"@lwc/errors": "8.
|
|
50
|
-
"@lwc/shared": "8.
|
|
49
|
+
"@lwc/errors": "8.20.0",
|
|
50
|
+
"@lwc/shared": "8.20.0",
|
|
51
51
|
"acorn": "~8.14.1",
|
|
52
52
|
"astring": "~1.9.0",
|
|
53
53
|
"he": "~1.2.0"
|