Skip to content
This repository has been archived by the owner on Oct 10, 2022. It is now read-only.

Commit

Permalink
📦 NEW: Use WP scripts with new externals
Browse files Browse the repository at this point in the history
  • Loading branch information
ahmadawais committed Nov 29, 2018
1 parent 7f1a247 commit 4b07131
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 14 deletions.
9 changes: 2 additions & 7 deletions packages/cgb-scripts/config/webpack.config.dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
*/

const paths = require( './paths' );
const externals = require( './externals' );
const autoprefixer = require( 'autoprefixer' );
const ExtractTextPlugin = require( 'extract-text-webpack-plugin' );

Expand Down Expand Up @@ -118,11 +119,5 @@ module.exports = {
stats: 'minimal',
// stats: 'errors-only',
// Add externals.
externals: {
react: 'React',
'react-dom': 'ReactDOM',
ga: 'ga', // Old Google Analytics.
gtag: 'gtag', // New Google Analytics.
jquery: 'jQuery', // import $ from 'jquery' // Use the WordPress version.
},
externals: externals,
};
9 changes: 2 additions & 7 deletions packages/cgb-scripts/config/webpack.config.prod.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@

const paths = require( './paths' );
const webpack = require( 'webpack' );
const externals = require( './externals' );
const autoprefixer = require( 'autoprefixer' );
const ExtractTextPlugin = require( 'extract-text-webpack-plugin' );

Expand Down Expand Up @@ -146,11 +147,5 @@ module.exports = {
stats: 'minimal',
// stats: 'errors-only',
// Add externals.
externals: {
react: 'React',
'react-dom': 'ReactDOM',
ga: 'ga', // Old Google Analytics.
gtag: 'gtag', // New Google Analytics.
jquery: 'jQuery', // import $ from 'jquery' // Use the WordPress version.
},
externals: externals,
};

0 comments on commit 4b07131

Please sign in to comment.