@marko/translator-default 5.21.1 → 5.21.4

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.js CHANGED
@@ -457,49 +457,49 @@ function getRuntimeEntryFiles(output, optimize) {
457
457
  const base = `marko/${optimize ? "dist" : "src"}/`;
458
458
 
459
459
  return [
460
- `${base}runtime/components`,
461
- `${base}runtime/components/defineComponent`,
462
- `${base}runtime/components/renderer`,
460
+ `${base}runtime/components/index.js`,
461
+ `${base}runtime/components/defineComponent.js`,
462
+ `${base}runtime/components/renderer.js`,
463
463
  `${base}runtime/components/registry`,
464
- `${base}runtime/components/attach-detach`,
465
- `${base}runtime/helpers/assign`,
466
- `${base}runtime/helpers/class-value`,
467
- `${base}runtime/helpers/dynamic-tag`,
468
- `${base}runtime/helpers/load-nested-tag`,
469
- `${base}runtime/helpers/merge`,
470
- `${base}runtime/helpers/render-tag`,
471
- `${base}runtime/helpers/style-value`,
472
- `${base}runtime/helpers/to-string`,
464
+ `${base}runtime/components/attach-detach.js`,
465
+ `${base}runtime/helpers/assign.js`,
466
+ `${base}runtime/helpers/class-value.js`,
467
+ `${base}runtime/helpers/dynamic-tag.js`,
468
+ `${base}runtime/helpers/load-nested-tag.js`,
469
+ `${base}runtime/helpers/merge.js`,
470
+ `${base}runtime/helpers/render-tag.js`,
471
+ `${base}runtime/helpers/style-value.js`,
472
+ `${base}runtime/helpers/to-string.js`,
473
473
  `${base}core-tags/components/preserve-tag`,
474
- `${base}core-tags/components/init-components-tag`,
475
- `${base}core-tags/components/preferred-script-location-tag`,
476
- `${base}core-tags/core/__flush_here_and_after__`,
477
- `${base}core-tags/core/await/renderer`,
478
- `${base}core-tags/core/await/reorderer-renderer`,
479
474
  ...(output === "html" ?
480
475
  [
481
- `${base}runtime/html`,
482
- `${base}runtime/html/hot-reload`,
483
- `${base}runtime/html/helpers/attr`,
484
- `${base}runtime/html/helpers/attrs`,
485
- `${base}runtime/html/helpers/class-attr`,
486
- `${base}runtime/html/helpers/data-marko`,
487
- `${base}runtime/html/helpers/escape-quotes`,
488
- `${base}runtime/html/helpers/escape-script-placeholder`,
489
- `${base}runtime/html/helpers/escape-style-placeholder`,
490
- `${base}runtime/html/helpers/escape-xml`,
491
- `${base}runtime/html/helpers/merge-attrs`,
492
- `${base}runtime/html/helpers/props-script`,
493
- `${base}runtime/html/helpers/style-attr`] :
476
+ `${base}runtime/html/index.js`,
477
+ `${base}runtime/html/hot-reload.js`,
478
+ `${base}runtime/html/helpers/attr.js`,
479
+ `${base}runtime/html/helpers/attrs.js`,
480
+ `${base}runtime/html/helpers/class-attr.js`,
481
+ `${base}runtime/html/helpers/data-marko.js`,
482
+ `${base}runtime/html/helpers/escape-quotes.js`,
483
+ `${base}runtime/html/helpers/escape-script-placeholder.js`,
484
+ `${base}runtime/html/helpers/escape-style-placeholder.js`,
485
+ `${base}runtime/html/helpers/escape-xml.js`,
486
+ `${base}runtime/html/helpers/merge-attrs.js`,
487
+ `${base}runtime/html/helpers/props-script.js`,
488
+ `${base}runtime/html/helpers/style-attr.js`,
489
+ `${base}core-tags/components/init-components-tag.js`,
490
+ `${base}core-tags/components/preferred-script-location-tag.js`,
491
+ `${base}core-tags/core/__flush_here_and_after__.js`,
492
+ `${base}core-tags/core/await/renderer.js`,
493
+ `${base}core-tags/core/await/reorderer-renderer.js`] :
494
494
 
495
495
  [
496
- `${base}runtime/vdom`,
497
- `${base}runtime/vdom/hot-reload`,
498
- `${base}runtime/vdom/helpers/attrs`,
499
- `${base}runtime/vdom/helpers/const`,
500
- `${base}runtime/vdom/helpers/v-element`,
501
- `${base}runtime/vdom/helpers/v-text`,
502
- `${base}runtime/vdom/preserve-attrs`])];
496
+ `${base}runtime/vdom/index.js`,
497
+ `${base}runtime/vdom/hot-reload.js`,
498
+ `${base}runtime/vdom/helpers/attrs.js`,
499
+ `${base}runtime/vdom/helpers/const.js`,
500
+ `${base}runtime/vdom/helpers/v-element.js`,
501
+ `${base}runtime/vdom/helpers/v-text.js`,
502
+ `${base}runtime/vdom/preserve-attrs.js`])];
503
503
 
504
504
 
505
505
  }
@@ -16,6 +16,15 @@ function buildIfStatement(path, args) {
16
16
 
17
17
  let nextPath = path.getNextSibling();
18
18
 
19
+ while (
20
+ nextPath.isMarkoComment() ||
21
+ nextPath.isMarkoText() && /^\s*$/.test(nextPath.node.value))
22
+ {
23
+ const ignorePath = nextPath;
24
+ nextPath = nextPath.getNextSibling();
25
+ ignorePath.remove();
26
+ }
27
+
19
28
  // Provide the if statement to the next part of the if chain.
20
29
  if (nextPath.isMarkoTag()) {
21
30
  const nextTagName = nextPath.get("name");
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@marko/translator-default",
3
3
  "description": "Translates Marko templates to the default Marko runtime.",
4
- "version": "5.21.1",
4
+ "version": "5.21.4",
5
5
  "author": "Dylan Piercey <dpiercey@ebay.com>",
6
6
  "bugs": "https://github.com/marko-js/marko/issues/new?template=Bug_report.md",
7
7
  "dependencies": {
@@ -12,8 +12,8 @@
12
12
  "self-closing-tags": "^1.0.1"
13
13
  },
14
14
  "devDependencies": {
15
- "@marko/compiler": "^5.21.1",
16
- "marko": "^5.21.1"
15
+ "@marko/compiler": "^5.21.7",
16
+ "marko": "^5.21.3"
17
17
  },
18
18
  "files": [
19
19
  "dist"