@lark-apaas/fullstack-rspack-preset 1.0.30-alpha.0 → 1.0.30-alpha.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/lib/overlay/index.js +1 -1
- package/lib/preset.js +1 -0
- package/package.json +1 -1
package/lib/overlay/index.js
CHANGED
|
@@ -131,7 +131,7 @@ function removeAllChildren(element, skip) {
|
|
|
131
131
|
}
|
|
132
132
|
function sendPostMessage(message, targetOrigin) {
|
|
133
133
|
try {
|
|
134
|
-
const parentOrigin =
|
|
134
|
+
const parentOrigin = process.env.FORCE_FRAMEWORK_DOMAIN_MAIN;
|
|
135
135
|
const origin = targetOrigin || parentOrigin;
|
|
136
136
|
if (!origin) {
|
|
137
137
|
return;
|
package/lib/preset.js
CHANGED
|
@@ -146,6 +146,7 @@ function createRecommendRspackConfig(options) {
|
|
|
146
146
|
'process.env.NODE_ENV': JSON.stringify(isDev ? 'development' : 'production'),
|
|
147
147
|
'process.env.runtimeMode': JSON.stringify('fullstack'),
|
|
148
148
|
'process.env.CLIENT_BASE_PATH': JSON.stringify(clientBasePath),
|
|
149
|
+
'process.env.FORCE_FRAMEWORK_DOMAIN_MAIN': JSON.stringify(process.env.FORCE_FRAMEWORK_DOMAIN_MAIN ?? ''),
|
|
149
150
|
'process.env.CWD': JSON.stringify(''),
|
|
150
151
|
// 解决 window 未定义问题
|
|
151
152
|
'typeof window': JSON.stringify('object'),
|