Skip to content

Commit

Permalink
New webpack.web.js configuration to substitute prod/staging
Browse files Browse the repository at this point in the history
  • Loading branch information
kidroca committed Feb 15, 2022
1 parent f3b03ac commit 77361f3
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions config/webpack/webpack.web.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
const {merge} = require('webpack-merge');
const dotenv = require('dotenv');
const common = require('./webpack.common');
const getProductionConfig = require('./productionConfig');

/**
* Builds a production grade web bundle
* @param {String} envFile path to the env file to be used
* @returns {Configuration}
*/
module.exports = ({envFile}) => {
const envConfig = dotenv.config({path: envFile});
return merge(common, getProductionConfig(envConfig.parsed));
};

0 comments on commit 77361f3

Please sign in to comment.