Skip to content

Commit

Permalink
sync with changes made facebook/create-react-app#5722
Browse files Browse the repository at this point in the history
  • Loading branch information
kaltepeter committed Dec 24, 2018
1 parent a1d0e24 commit cd8ddd7
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ This script is inspired by other work related such as: https://gist.github.com/j

## Ejection

This tool handles ejected projects but it assumes you did not modify your `webpack.config.dev.js` file, `paths.js` and `env.js` utils. If you did I cannot guarantee that this tool will work.
This tool handles ejected projects but it assumes you did not modify your `webpack.config.js` file, `paths.js` and `env.js` utils. If you did I cannot guarantee that this tool will work.

# Why do I need this?

Expand Down
4 changes: 2 additions & 2 deletions scripts/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ const { getReactScriptsVersion, isEjected } = require('../utils');
const paths = isEjected ? importCwd('./config/paths') : importCwd('react-scripts/config/paths');
const webpack = importCwd('webpack');
const config = isEjected
? importCwd('./config/webpack.config.dev')
: importCwd('react-scripts/config/webpack.config.dev');
? importCwd('./config/webpack.config')('development')
: importCwd('react-scripts/config/webpack.config')('development');
const HtmlWebpackPlugin = importCwd('html-webpack-plugin');
const InterpolateHtmlPlugin = importCwd('react-dev-utils/InterpolateHtmlPlugin');
const getClientEnvironment = isEjected
Expand Down
2 changes: 1 addition & 1 deletion utils/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ const DEFAULT_VERSION = {
patch: 4,
};

exports.isEjected = fs.pathExistsSync(path.join(process.cwd(), 'config/webpack.config.dev.js'));
exports.isEjected = fs.pathExistsSync(path.join(process.cwd(), 'config/webpack.config.js'));

exports.getReactScriptsVersion = function getReactScriptsVersion(cliVersion) {
if (cliVersion) {
Expand Down

0 comments on commit cd8ddd7

Please sign in to comment.