@bigcommerce/stencil-cli 3.6.2 → 3.6.3
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 +5 -0
- package/lib/stencil-start.js +2 -1
- package/package-lock.json +384 -23882
- package/package.json +2 -2
- package/server/index.js +1 -0
- package/server/plugins/router/router.module.js +10 -5
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bigcommerce/stencil-cli",
|
|
3
|
-
"version": "3.6.
|
|
3
|
+
"version": "3.6.3",
|
|
4
4
|
"description": "CLI tool to run BigCommerce Stores locally for theme development.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"engines": {
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"package-lock.json"
|
|
45
45
|
],
|
|
46
46
|
"dependencies": {
|
|
47
|
-
"@bigcommerce/stencil-paper": "^3.0.0-rc.
|
|
47
|
+
"@bigcommerce/stencil-paper": "^3.0.0-rc.51",
|
|
48
48
|
"@bigcommerce/stencil-styles": "2.1.0",
|
|
49
49
|
"@hapi/boom": "^8.0.1",
|
|
50
50
|
"@hapi/glue": "^6.2.0",
|
package/server/index.js
CHANGED
|
@@ -19,6 +19,7 @@ function buildManifest(srcManifest, options) {
|
|
|
19
19
|
parsedNormalUrl.protocol + '//' + parsedNormalUrl.host;
|
|
20
20
|
pluginsByName['./plugins/router/router.module'].apiKey = options.dotStencilFile.apiKey;
|
|
21
21
|
pluginsByName['./plugins/router/router.module'].port = options.dotStencilFile.port;
|
|
22
|
+
pluginsByName['./plugins/router/router.module'].stencilCliVersion = options.stencilCliVersion;
|
|
22
23
|
pluginsByName['./plugins/renderer/renderer.module'].useCache = options.useCache;
|
|
23
24
|
pluginsByName['./plugins/renderer/renderer.module'].username = options.dotStencilFile.username;
|
|
24
25
|
pluginsByName['./plugins/renderer/renderer.module'].token = options.dotStencilFile.token;
|
|
@@ -98,7 +98,6 @@ internals.registerRoutes = (server) => {
|
|
|
98
98
|
protocol: 'https',
|
|
99
99
|
port: 443,
|
|
100
100
|
passThrough: true,
|
|
101
|
-
xforward: false,
|
|
102
101
|
},
|
|
103
102
|
},
|
|
104
103
|
options: {
|
|
@@ -112,12 +111,18 @@ internals.registerRoutes = (server) => {
|
|
|
112
111
|
path: internals.paths.storefrontAPI,
|
|
113
112
|
handler: {
|
|
114
113
|
proxy: {
|
|
115
|
-
host: internals.options.storeUrl.replace(/http[s]?:\/\//, ''),
|
|
116
114
|
rejectUnauthorized: false,
|
|
117
|
-
|
|
118
|
-
|
|
115
|
+
mapUri: (req) => {
|
|
116
|
+
const host = `https://${internals.options.storeUrl.replace(
|
|
117
|
+
/http[s]?:\/\//,
|
|
118
|
+
'',
|
|
119
|
+
)}`;
|
|
120
|
+
const urlParams = req.url.search || '';
|
|
121
|
+
const uri = `${host}${req.path}${urlParams}`;
|
|
122
|
+
const headers = { 'stencil-cli': internals.options.stencilCliVersion };
|
|
123
|
+
return { uri, headers };
|
|
124
|
+
},
|
|
119
125
|
passThrough: true,
|
|
120
|
-
xforward: false,
|
|
121
126
|
},
|
|
122
127
|
},
|
|
123
128
|
options: {
|