Skip to content

Commit ec32918

Browse files
committed
🔧 Change the webpack configs to parse the env variables
1 parent b0e6c75 commit ec32918

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

.electron-vue/webpack.main.config.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,12 +61,12 @@ if (process.env.NODE_ENV === "production") {
6161
mainConfig.plugins.push(
6262
new BabiliWebpackPlugin(),
6363
new webpack.DefinePlugin({
64-
'process.env.NODE_ENV': '"production"',
64+
'process.env.NODE_ENV': '"production"',
6565
'process.env': require("dotenv").config({
6666
path: path.join(__dirname, "../.env")
67-
}).parsed
67+
}).parsed
6868
})
69-
);
69+
);
7070
}
7171

7272
module.exports = mainConfig;

.electron-vue/webpack.renderer.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ if (process.env.NODE_ENV === 'production') {
163163
'process.env.NODE_ENV': '"production"',
164164
'process.env': require("dotenv").config({
165165
path: path.join(__dirname, "../.env")
166-
}).parsed
166+
}).parsed
167167
}),
168168
new webpack.LoaderOptionsPlugin({
169169
minimize: true

0 commit comments

Comments
 (0)