Skip to content

Commit

Permalink
fix(main): check extends section for existence
Browse files Browse the repository at this point in the history
  • Loading branch information
oklas authored Jun 14, 2022
1 parent 80c8a06 commit 699bcb3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion packages/react-app-alias/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -143,8 +143,10 @@ function readConfig(confPath) {

const extUrl = conf.extends
const extPath = extUrl ? path.resolve(confdir, extUrl) : ''
if(extPath && !fs.existsSync(extPath))
throw Error(`react-app-alias:readConfig: '${confPath}' field 'extends' is '${extPath}' - not exists'`)
conf.extends = extUrl ? require(extPath) : {}

return conf
}

Expand Down

0 comments on commit 699bcb3

Please sign in to comment.