marko 5.37.37 → 5.37.39
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/translator/taglib/core/index.js +2 -2
- package/dist/translator/taglib/core/transform-body.js +15 -0
- package/package.json +2 -2
- package/src/translator/taglib/core/index.js +2 -2
- package/src/translator/taglib/core/{translate-body.js → transform-body.js} +4 -6
- package/dist/translator/taglib/core/translate-body.js +0 -17
@@ -8,9 +8,9 @@ var parseExport = _interopRequireWildcard(require("./parse-export"));
|
|
8
8
|
var parseImport = _interopRequireWildcard(require("./parse-import"));
|
9
9
|
var parseModuleCode = _interopRequireWildcard(require("./parse-module-code"));
|
10
10
|
var parseStatic = _interopRequireWildcard(require("./parse-static"));
|
11
|
+
var transformBody = _interopRequireWildcard(require("./transform-body"));
|
11
12
|
var transformStyle = _interopRequireWildcard(require("./transform-style"));
|
12
13
|
var translateAwait = _interopRequireWildcard(require("./translate-await"));
|
13
|
-
var translateBody = _interopRequireWildcard(require("./translate-body"));
|
14
14
|
var translateFor = _interopRequireWildcard(require("./translate-for"));
|
15
15
|
var translateHTMLComment = _interopRequireWildcard(require("./translate-html-comment"));
|
16
16
|
var translateIncludeContent = _interopRequireWildcard(require("./translate-include-content"));
|
@@ -284,7 +284,7 @@ var translateWhile = _interopRequireWildcard(require("./translate-while"));funct
|
|
284
284
|
renderer: "marko/src/core-tags/components/preferred-script-location-tag.js"
|
285
285
|
},
|
286
286
|
"<body>": {
|
287
|
-
|
287
|
+
transformer: transformBody
|
288
288
|
},
|
289
289
|
"<await>": {
|
290
290
|
renderer: "marko/src/core-tags/core/await/renderer.js",
|
@@ -0,0 +1,15 @@
|
|
1
|
+
"use strict";exports.__esModule = true;exports.default = _default;var _compiler = require("@marko/compiler");
|
2
|
+
|
3
|
+
function _default(path) {
|
4
|
+
path.
|
5
|
+
get("body").
|
6
|
+
pushContainer("body", [
|
7
|
+
_compiler.types.markoTag(_compiler.types.stringLiteral("init-components"), [], _compiler.types.markoTagBody()),
|
8
|
+
_compiler.types.markoTag(_compiler.types.stringLiteral("await-reorderer"), [], _compiler.types.markoTagBody()),
|
9
|
+
_compiler.types.markoTag(
|
10
|
+
_compiler.types.stringLiteral("_preferred-script-location"),
|
11
|
+
[],
|
12
|
+
_compiler.types.markoTagBody()
|
13
|
+
)]
|
14
|
+
);
|
15
|
+
}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "marko",
|
3
|
-
"version": "5.37.
|
3
|
+
"version": "5.37.39",
|
4
4
|
"description": "UI Components + streaming, async, high performance, HTML templating for Node.js and the browser.",
|
5
5
|
"keywords": [
|
6
6
|
"front-end",
|
@@ -70,7 +70,7 @@
|
|
70
70
|
},
|
71
71
|
"dependencies": {
|
72
72
|
"@babel/runtime": "^7.27.0",
|
73
|
-
"@marko/compiler": "^5.39.
|
73
|
+
"@marko/compiler": "^5.39.27",
|
74
74
|
"app-module-path": "^2.2.0",
|
75
75
|
"argly": "^1.2.0",
|
76
76
|
"browser-refresh-client": "1.1.4",
|
@@ -8,9 +8,9 @@ import * as parseExport from "./parse-export";
|
|
8
8
|
import * as parseImport from "./parse-import";
|
9
9
|
import * as parseModuleCode from "./parse-module-code";
|
10
10
|
import * as parseStatic from "./parse-static";
|
11
|
+
import * as transformBody from "./transform-body";
|
11
12
|
import * as transformStyle from "./transform-style";
|
12
13
|
import * as translateAwait from "./translate-await";
|
13
|
-
import * as translateBody from "./translate-body";
|
14
14
|
import * as translateFor from "./translate-for";
|
15
15
|
import * as translateHTMLComment from "./translate-html-comment";
|
16
16
|
import * as translateIncludeContent from "./translate-include-content";
|
@@ -284,7 +284,7 @@ export default {
|
|
284
284
|
renderer: "marko/src/core-tags/components/preferred-script-location-tag.js",
|
285
285
|
},
|
286
286
|
"<body>": {
|
287
|
-
|
287
|
+
transformer: transformBody,
|
288
288
|
},
|
289
289
|
"<await>": {
|
290
290
|
renderer: "marko/src/core-tags/core/await/renderer.js",
|
@@ -1,10 +1,9 @@
|
|
1
1
|
import { types as t } from "@marko/compiler";
|
2
2
|
|
3
|
-
export function
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
body.pushContainer("body", [
|
3
|
+
export default function (path) {
|
4
|
+
path
|
5
|
+
.get("body")
|
6
|
+
.pushContainer("body", [
|
8
7
|
t.markoTag(t.stringLiteral("init-components"), [], t.markoTagBody()),
|
9
8
|
t.markoTag(t.stringLiteral("await-reorderer"), [], t.markoTagBody()),
|
10
9
|
t.markoTag(
|
@@ -13,5 +12,4 @@ export function enter(path) {
|
|
13
12
|
t.markoTagBody(),
|
14
13
|
),
|
15
14
|
]);
|
16
|
-
}
|
17
15
|
}
|
@@ -1,17 +0,0 @@
|
|
1
|
-
"use strict";exports.__esModule = true;exports.enter = enter;var _compiler = require("@marko/compiler");
|
2
|
-
|
3
|
-
function enter(path) {
|
4
|
-
if (path.hub.file.markoOpts.output === "html") {
|
5
|
-
const body = path.get("body");
|
6
|
-
|
7
|
-
body.pushContainer("body", [
|
8
|
-
_compiler.types.markoTag(_compiler.types.stringLiteral("init-components"), [], _compiler.types.markoTagBody()),
|
9
|
-
_compiler.types.markoTag(_compiler.types.stringLiteral("await-reorderer"), [], _compiler.types.markoTagBody()),
|
10
|
-
_compiler.types.markoTag(
|
11
|
-
_compiler.types.stringLiteral("_preferred-script-location"),
|
12
|
-
[],
|
13
|
-
_compiler.types.markoTagBody()
|
14
|
-
)]
|
15
|
-
);
|
16
|
-
}
|
17
|
-
}
|