Skip to content

Commit

Permalink
🔧 Change the webpack configs to parse the env variables
Browse files Browse the repository at this point in the history
  • Loading branch information
lunaticmonk committed Jan 10, 2019
1 parent b0e6c75 commit ec32918
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions .electron-vue/webpack.main.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,12 @@ if (process.env.NODE_ENV === "production") {
mainConfig.plugins.push(
new BabiliWebpackPlugin(),
new webpack.DefinePlugin({
'process.env.NODE_ENV': '"production"',
'process.env.NODE_ENV': '"production"',
'process.env': require("dotenv").config({
path: path.join(__dirname, "../.env")
}).parsed
}).parsed
})
);
);
}

module.exports = mainConfig;
2 changes: 1 addition & 1 deletion .electron-vue/webpack.renderer.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ if (process.env.NODE_ENV === 'production') {
'process.env.NODE_ENV': '"production"',
'process.env': require("dotenv").config({
path: path.join(__dirname, "../.env")
}).parsed
}).parsed
}),
new webpack.LoaderOptionsPlugin({
minimize: true
Expand Down

0 comments on commit ec32918

Please sign in to comment.