File tree Expand file tree Collapse file tree 1 file changed +9
-9
lines changed
packages/react-scripts/config Expand file tree Collapse file tree 1 file changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -347,16 +347,16 @@ module.exports = function(webpackEnv) {
347347 // @remove -on-eject-begin
348348 ignore : process . env . EXTEND_ESLINT === 'true' ,
349349 baseConfig : ( ( ) => {
350- const eslintCli = new eslint . CLIEngine ( ) ;
351- let eslintConfig ;
352- try {
353- eslintConfig = eslintCli . getConfigForFile ( paths . appIndexJs ) ;
354- } catch ( e ) {
355- // A config couldn't be found.
356- }
357-
358350 // We allow overriding the config only if the env variable is set
359- if ( process . env . EXTEND_ESLINT === 'true' && eslintConfig ) {
351+ if ( process . env . EXTEND_ESLINT === 'true' ) {
352+ const eslintCli = new eslint . CLIEngine ( ) ;
353+ let eslintConfig ;
354+ try {
355+ eslintConfig = eslintCli . getConfigForFile ( paths . appIndexJs ) ;
356+ } catch ( e ) {
357+ console . error ( e ) ;
358+ process . exit ( 1 ) ;
359+ }
360360 return eslintConfig ;
361361 } else {
362362 return {
You can’t perform that action at this time.
0 commit comments