Commit 80765677 authored by Harun's avatar Harun Committed by Dan Abramov
Browse files

Remove path module from webpack config on eject. (#1175)

* Remove path module from webpack config on eject.

Fixes #1174

* Move path module inclusion right after the other imports

Re: #1174
parent f7d9cd81
No related merge requests found
Showing with 10 additions and 2 deletions
+10 -2
......@@ -9,7 +9,6 @@
*/
// @remove-on-eject-end
var path = require('path');
var autoprefixer = require('autoprefixer');
var webpack = require('webpack');
var HtmlWebpackPlugin = require('html-webpack-plugin');
......@@ -19,6 +18,11 @@ var WatchMissingNodeModulesPlugin = require('react-dev-utils/WatchMissingNodeMod
var getClientEnvironment = require('./env');
var paths = require('./paths');
// @remove-on-eject-begin
// `path` is not used after eject - see https://github.com/facebookincubator/create-react-app/issues/1174
var path = require('path');
// @remove-on-eject-end
// Webpack uses `publicPath` to determine where the app is being served from.
// In development, we always serve from the root. This makes config easier.
var publicPath = '/';
......
......@@ -9,7 +9,6 @@
*/
// @remove-on-eject-end
var path = require('path');
var autoprefixer = require('autoprefixer');
var webpack = require('webpack');
var HtmlWebpackPlugin = require('html-webpack-plugin');
......@@ -20,6 +19,11 @@ var url = require('url');
var paths = require('./paths');
var getClientEnvironment = require('./env');
// @remove-on-eject-begin
// `path` is not used after eject - see https://github.com/facebookincubator/create-react-app/issues/1174
var path = require('path');
// @remove-on-eject-end
function ensureSlash(path, needsSlash) {
var hasSlash = path.endsWith('/');
if (hasSlash && !needsSlash) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment