@speedkit/cli 2.52.0 → 2.53.1
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/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,18 @@
|
|
|
1
|
+
## [2.53.1](https://gitlab.orestes.info/baqend/speed-kit-cli/compare/v2.53.0...v2.53.1) (2024-08-22)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* **customer-config:** add prevention for having body as main block for pre-rendering ([132eeb3](https://gitlab.orestes.info/baqend/speed-kit-cli/commit/132eeb37493221b3b90fb16fa4649068a560a607))
|
|
7
|
+
|
|
8
|
+
# [2.53.0](https://gitlab.orestes.info/baqend/speed-kit-cli/compare/v2.52.0...v2.53.0) (2024-08-22)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Features
|
|
12
|
+
|
|
13
|
+
* **customer-config:** restore shopify-specific block config ([0e52434](https://gitlab.orestes.info/baqend/speed-kit-cli/commit/0e52434ad7b6dde866bf5b006d7b138c124d8282))
|
|
14
|
+
* **customer-config:** set body as default main block ([d600453](https://gitlab.orestes.info/baqend/speed-kit-cli/commit/d6004538cdd0daf86d7776cd95dd91a714b7635a))
|
|
15
|
+
|
|
1
16
|
# [2.52.0](https://gitlab.orestes.info/baqend/speed-kit-cli/compare/v2.51.0...v2.52.0) (2024-08-09)
|
|
2
17
|
|
|
3
18
|
|
package/README.md
CHANGED
|
@@ -1,32 +1,33 @@
|
|
|
1
1
|
(function() {
|
|
2
2
|
{{#if addPreRendering}}
|
|
3
3
|
{{#unless supportShadowDomInPreRendering}}
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
4
|
+
const PRERENDER_TIMEOUT = 30_000; // 30s
|
|
5
|
+
const PRERENDER_CHECK_INTERVAL = 300; // 300ms
|
|
6
|
+
const preRenderedRootConfig = [
|
|
7
|
+
// TODO: adjust/replace this exemplary list
|
|
8
|
+
{
|
|
9
|
+
selector: "body > #app, #speed-kit-pre-rendered-app",
|
|
10
|
+
detectChanges: [
|
|
11
|
+
{
|
|
12
|
+
// header area
|
|
13
|
+
find: "#page-root > div > .aem-container > div:nth-of-type(1)",
|
|
14
|
+
detectChanges: [
|
|
15
|
+
// main categories
|
|
16
|
+
{
|
|
17
|
+
find: 'button[id^="menu-button"] p',
|
|
18
|
+
compare: ["text"],
|
|
19
|
+
},
|
|
20
|
+
// logo
|
|
21
|
+
{
|
|
22
|
+
find: "img[src]",
|
|
23
|
+
compare: ["src"],
|
|
24
|
+
},
|
|
25
|
+
],
|
|
26
|
+
},
|
|
27
|
+
],
|
|
28
|
+
},
|
|
29
|
+
];
|
|
30
|
+
|
|
30
31
|
{{/unless}}
|
|
31
32
|
{{/if}}
|
|
32
33
|
/**
|
|
@@ -46,63 +47,80 @@
|
|
|
46
47
|
{{/if}}
|
|
47
48
|
|
|
48
49
|
blocks: [
|
|
49
|
-
// TODO: adjust/replace this exemplary list
|
|
50
50
|
{{#if addPreRendering}}
|
|
51
51
|
{{#unless supportShadowDomInPreRendering}}
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
52
|
+
...preRenderedRootConfig.map((config) => {
|
|
53
|
+
return {
|
|
54
|
+
selector: config.selector,
|
|
55
|
+
merge: (localBlock, remoteBlock) => {
|
|
56
|
+
handlePreRenderBlock(localBlock, remoteBlock);
|
|
57
|
+
},
|
|
58
|
+
detectChanges: false,
|
|
59
|
+
};
|
|
60
|
+
}),
|
|
61
|
+
|
|
61
62
|
{{/unless}}
|
|
62
63
|
{{/if}}
|
|
64
|
+
// TODO: adjust/replace this exemplary list
|
|
63
65
|
|
|
64
|
-
{{#if isShopify}}
|
|
65
|
-
// Shopify specific:
|
|
66
|
-
{
|
|
67
|
-
selector: "#shopify-section-announcement-bar",
|
|
68
|
-
detectChanges: [{
|
|
69
|
-
find: ".announcement-bar--wrapper",
|
|
70
|
-
compare: ["text"],
|
|
71
|
-
}],
|
|
72
|
-
},
|
|
73
|
-
// cover all the other high-level Shopify sections:
|
|
74
|
-
{
|
|
75
|
-
selector: "body > .shopify-section[id]",
|
|
76
|
-
idAttribute: "id",
|
|
77
|
-
},
|
|
78
|
-
|
|
79
|
-
{{/if}}
|
|
80
66
|
{
|
|
67
|
+
{{#if addPreRendering}}
|
|
81
68
|
selector: '#main',
|
|
69
|
+
{{else}}
|
|
70
|
+
selector: 'body',
|
|
71
|
+
{{/if}}
|
|
82
72
|
detectChanges: [
|
|
83
|
-
|
|
84
|
-
// home teaser:
|
|
73
|
+
// Main Headline:
|
|
85
74
|
{
|
|
86
|
-
find: '
|
|
87
|
-
compare: ['
|
|
75
|
+
find: 'h1',
|
|
76
|
+
compare: ['text'],
|
|
88
77
|
},
|
|
78
|
+
|
|
79
|
+
// Home:
|
|
89
80
|
{
|
|
90
|
-
find: '.teaser source',
|
|
81
|
+
find: '.stage-teaser source',
|
|
91
82
|
compare: ['srcset'],
|
|
92
83
|
},
|
|
93
84
|
|
|
94
|
-
//
|
|
85
|
+
// PLP:
|
|
95
86
|
{
|
|
96
|
-
find: '.product-grid .product
|
|
87
|
+
find: '.product-grid .product img',
|
|
97
88
|
limit: 9, // only compare the first 9 products
|
|
98
|
-
compare: ['
|
|
89
|
+
compare: ['src'],
|
|
99
90
|
},
|
|
100
91
|
// ...
|
|
101
92
|
|
|
102
|
-
//
|
|
93
|
+
// PDP:
|
|
103
94
|
// ...
|
|
104
95
|
],
|
|
105
96
|
},
|
|
97
|
+
{{#if isShopify}}
|
|
98
|
+
|
|
99
|
+
// Shopify specific:
|
|
100
|
+
{
|
|
101
|
+
selector: "#shopify-section-announcement-bar",
|
|
102
|
+
{{#unless addPreRendering}}
|
|
103
|
+
merge: false, // TODO: remove if body is not the main block
|
|
104
|
+
{{/unless}}
|
|
105
|
+
detectChanges: [{
|
|
106
|
+
find: ".announcement-bar--wrapper",
|
|
107
|
+
compare: ["text"],
|
|
108
|
+
}],
|
|
109
|
+
},
|
|
110
|
+
// Cover all the other high-level Shopify sections:
|
|
111
|
+
{{#if addPreRendering}}
|
|
112
|
+
{
|
|
113
|
+
selector: "body > .shopify-section[id]",
|
|
114
|
+
idAttribute: "id",
|
|
115
|
+
},
|
|
116
|
+
{{else}}
|
|
117
|
+
// TODO: activate if body is not the main block
|
|
118
|
+
// {
|
|
119
|
+
// selector: "body > .shopify-section[id]",
|
|
120
|
+
// idAttribute: "id",
|
|
121
|
+
// },
|
|
122
|
+
{{/if}}
|
|
123
|
+
{{/if}}
|
|
106
124
|
{{#if isPlentymarkets}}
|
|
107
125
|
|
|
108
126
|
// Plentymarkets specific:
|
package/oclif.manifest.json
CHANGED