@ecopages/lit 0.2.0-beta.13 → 0.2.0-beta.14
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ecopages/lit",
|
|
3
|
-
"version": "0.2.0-beta.
|
|
3
|
+
"version": "0.2.0-beta.14",
|
|
4
4
|
"description": "Ecopages lit integration",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ecopages",
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"directory": "packages/integrations/lit"
|
|
40
40
|
},
|
|
41
41
|
"peerDependencies": {
|
|
42
|
-
"@ecopages/core": "0.2.0-beta.
|
|
42
|
+
"@ecopages/core": "0.2.0-beta.14",
|
|
43
43
|
"@lit-labs/ssr": "^3.3.0",
|
|
44
44
|
"@lit-labs/ssr-client": "^1.1.7",
|
|
45
45
|
"lit": "^3.2.1"
|
package/src/lit-renderer.js
CHANGED
|
@@ -203,7 +203,8 @@ class LitRenderer extends IntegrationRenderer {
|
|
|
203
203
|
});
|
|
204
204
|
}
|
|
205
205
|
const viewConfig = view.config;
|
|
206
|
-
const
|
|
206
|
+
const layouts = viewConfig?.layouts;
|
|
207
|
+
const Layout = layouts?.[layouts.length - 1];
|
|
207
208
|
const HtmlTemplate = await this.getHtmlTemplate();
|
|
208
209
|
const metadata = await this.resolveViewMetadata(view, props);
|
|
209
210
|
const normalizedProps = props ?? {};
|
|
@@ -60,8 +60,8 @@ class LitSsrLazyPreloader {
|
|
|
60
60
|
scriptPaths.add(this.resolveDependencyPath(componentDir, script.src));
|
|
61
61
|
}
|
|
62
62
|
}
|
|
63
|
-
|
|
64
|
-
collect(
|
|
63
|
+
for (const layout of config.layouts ?? []) {
|
|
64
|
+
collect(layout);
|
|
65
65
|
}
|
|
66
66
|
for (const nestedComponent of config.dependencies?.components || []) {
|
|
67
67
|
collect(nestedComponent);
|
|
@@ -60,8 +60,8 @@ class LitStaticRenderSession {
|
|
|
60
60
|
const page = pageModule.default;
|
|
61
61
|
if (page) {
|
|
62
62
|
components.push(page);
|
|
63
|
-
|
|
64
|
-
components.push(
|
|
63
|
+
for (const layout of page.config?.layouts ?? []) {
|
|
64
|
+
components.push(layout);
|
|
65
65
|
}
|
|
66
66
|
for (const nestedComponent of page.config?.dependencies?.components ?? []) {
|
|
67
67
|
components.push(nestedComponent);
|