@marko/compiler 5.39.64 → 5.39.65
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/babel-plugin/parser.js +10 -0
- package/package.json +1 -1
|
@@ -629,6 +629,16 @@ function parseMarko(file) {
|
|
|
629
629
|
}
|
|
630
630
|
|
|
631
631
|
if (isControlFlow) {
|
|
632
|
+
if (!parentTag) {
|
|
633
|
+
onNext();
|
|
634
|
+
throw file.buildCodeFrameError(
|
|
635
|
+
attributeTags.find(
|
|
636
|
+
(child) => _babel.types.isMarkoTag(child) && isAttrTag(child)
|
|
637
|
+
)?.name || node.name,
|
|
638
|
+
"@tags must be nested within another element."
|
|
639
|
+
);
|
|
640
|
+
}
|
|
641
|
+
|
|
632
642
|
currentTag.remove();
|
|
633
643
|
parentTag.pushContainer("attributeTags", node);
|
|
634
644
|
}
|