@quintype/framework 7.4.1-amp-fix.4 → 7.4.1-test-amp.0
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": "@quintype/framework",
|
|
3
|
-
"version": "7.4.1-amp
|
|
3
|
+
"version": "7.4.1-test-amp.0",
|
|
4
4
|
"description": "Libraries to help build Quintype Node.js apps",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"engines": {
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
"homepage": "https://github.com/quintype/quintype-node-framework#readme",
|
|
32
32
|
"dependencies": {
|
|
33
33
|
"@ampproject/toolbox-optimizer": "2.8.3",
|
|
34
|
-
"@quintype/amp": "^2.4.
|
|
34
|
+
"@quintype/amp": "^2.4.22-test-madrid.0",
|
|
35
35
|
"@quintype/backend": "^2.3.1",
|
|
36
36
|
"@quintype/components": "^3.0.0",
|
|
37
37
|
"@quintype/prerender-node": "^3.2.24",
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
const urlLib = require("url");
|
|
2
2
|
const set = require("lodash/set");
|
|
3
3
|
const get = require("lodash/get");
|
|
4
|
-
const isEmpty = require("lodash/isEmpty");
|
|
5
4
|
const cloneDeep = require("lodash/cloneDeep");
|
|
6
5
|
const merge = require("lodash/merge");
|
|
7
6
|
const { Story, AmpConfig } = require("../../impl/api-client-impl");
|
|
@@ -104,7 +103,6 @@ async function ampStoryPageHandler(
|
|
|
104
103
|
infiniteScrollInlineConfig
|
|
105
104
|
);
|
|
106
105
|
}
|
|
107
|
-
const mergedAdditionalConfig = {};
|
|
108
106
|
if (opts.getAdditionalConfig && opts.getAdditionalConfig instanceof Function) {
|
|
109
107
|
const fetchedAdditionalConfig = await opts.getAdditionalConfig({
|
|
110
108
|
story,
|
|
@@ -112,14 +110,14 @@ async function ampStoryPageHandler(
|
|
|
112
110
|
ampApiConfig: ampConfig.ampConfig,
|
|
113
111
|
publisherConfig: additionalConfig,
|
|
114
112
|
});
|
|
115
|
-
merge(
|
|
113
|
+
merge(additionalConfig, fetchedAdditionalConfig);
|
|
116
114
|
}
|
|
117
115
|
|
|
118
116
|
const ampHtml = ampifyStory({
|
|
119
117
|
story,
|
|
120
118
|
publisherConfig: config.config,
|
|
121
119
|
ampConfig: ampConfig.ampConfig,
|
|
122
|
-
additionalConfig
|
|
120
|
+
additionalConfig,
|
|
123
121
|
opts: { ...domainSpecificOpts, domainSlug },
|
|
124
122
|
seo: seoTags ? seoTags.toString() : "",
|
|
125
123
|
});
|