@lwc/template-compiler 5.2.1 → 5.3.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 CHANGED
@@ -13086,7 +13086,10 @@ class CodeGen {
13086
13086
  // Depth-first traversal. We assign a partId to each element, which is an integer based on traversal order.
13087
13087
  while (stack.length > 0) {
13088
13088
  const node = stack.shift();
13089
- partId++;
13089
+ // Skip comment nodes in parts count, as they will be stripped in production, unless when `lwc:preserve-comments` is enabled
13090
+ if (!isComment(node) || this.preserveComments) {
13091
+ partId++;
13092
+ }
13090
13093
  if (isElement(node)) {
13091
13094
  // has event listeners
13092
13095
  if (node.listeners.length) {
@@ -13842,5 +13845,5 @@ function compile(source, config) {
13842
13845
  exports.compile = compile;
13843
13846
  exports.default = compile;
13844
13847
  exports.parse = parse;
13845
- /** version: 5.2.1 */
13848
+ /** version: 5.3.0 */
13846
13849
  //# sourceMappingURL=index.cjs.js.map