Skip to content

Commit

Permalink
fix:add clent env parameter HOSTAPI (#43)
Browse files Browse the repository at this point in the history
* fix:add clent env parameter HOSTAPI

* doc:添加 command help

Co-authored-by: SunLxy <1011771396@qq.com>
  • Loading branch information
wj0990 and SunLxy committed Dec 7, 2022
1 parent 14afff9 commit cd41793
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion core/src/utils/plugins/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ export const AddDefinePlugin = (conf: WebpackConfiguration, overrides: Overrides
/** start 模式下 文件获取地址 */
HOSTAPI: JSON.stringify(undefined),
"process.env.PORT": JSON.stringify(PORT),
"process.env.HOSTAPI": JSON.stringify(undefined),
"process.env.HOSTAPI": JSON.stringify(process.env.HOSTAPI || undefined),
"process.env.HOST": JSON.stringify(HOST)
}

Expand Down
2 changes: 1 addition & 1 deletion packages/kkt-plugin-ssr/src/childCompiler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ const getCreateChildCompiler = (compilation: webpack.Compilation, options: Webpa
/** start 模式下 文件获取地址 */
HOSTAPI: JSON.stringify(undefined),
"process.env.PORT": JSON.stringify(PORT),
"process.env.HOSTAPI": JSON.stringify(undefined),
"process.env.HOSTAPI": JSON.stringify(process.env.HOSTAPI || undefined),
"process.env.HOST": JSON.stringify(HOST)
}

Expand Down

0 comments on commit cd41793

Please sign in to comment.