Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

Commit

Permalink
fix(electron): addlow DEBUG_PROD in production builds
Browse files Browse the repository at this point in the history
  • Loading branch information
mrfelton committed Dec 17, 2018
1 parent cc25ad6 commit ab8a55a
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 12 deletions.
2 changes: 1 addition & 1 deletion app/main.dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ app.on('ready', async () => {
/**
* In development mode or when DEBUG_PROD is set, enable debugging tools.
*/
if (process.env.NODE_ENV === 'development' || process.env.DEBUG_PROD === 'true') {
if (process.env.NODE_ENV === 'development' || process.env.DEBUG_PROD) {
installExtension(REACT_DEVELOPER_TOOLS)
.then(name => mainLog.debug(`Added Extension: ${name}`))
.catch(err => mainLog.warn(`An error occurred when installing REACT_DEVELOPER_TOOLS: ${err}`))
Expand Down
11 changes: 0 additions & 11 deletions internals/webpack/webpack.config.main.prod.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
*/

import path from 'path'
import webpack from 'webpack'
import merge from 'webpack-merge'
import { BundleAnalyzerPlugin } from 'webpack-bundle-analyzer'
import baseConfig, { rootDir } from './webpack.config.base'
Expand All @@ -30,16 +29,6 @@ export default merge.smart(baseConfig, {
new BundleAnalyzerPlugin({
analyzerMode: process.env.OPEN_ANALYZER === 'true' ? 'server' : 'disabled',
openAnalyzer: process.env.OPEN_ANALYZER === 'true'
}),

/**
* Create global constants which can be configured at compile time.
*
* Useful for allowing different behaviour between development builds and
* release builds
*/
new webpack.EnvironmentPlugin({
DEBUG_PROD: false
})
],

Expand Down

0 comments on commit ab8a55a

Please sign in to comment.