question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cannot read property 'exclude' of undefined at applyDefaults

See original GitHub issue

screenshot from 2017-04-10 16-59-27

Bug Report or Feature Request (mark with an x)

ERROR in ./src/main.ts
Module build failed: TypeError: Cannot read property 'exclude' of undefined
    at applyDefaults (/home/daffodil-201/Desktop/backup/beverage-ecommerce-maintenance/node_modules/awesome-typescript-loader/src/instance.ts:266:72)
    at Object.ensureInstance (/home/daffodil-201/Desktop/backup/beverage-ecommerce-maintenance/node_modules/awesome-typescript-loader/src/instance.ts:145:5)
    at compiler (/home/daffodil-201/Desktop/backup/beverage-ecommerce-maintenance/node_modules/awesome-typescript-loader/src/index.ts:37:20)
    at Object.loader (/home/daffodil-201/Desktop/backup/beverage-ecommerce-maintenance/node_modules/awesome-typescript-loader/src/index.ts:18:18)
 @ multi main

Issue

Hello, I’m using angular cli and I updated my app to angular4 using "npm install @angular/{common,compiler,compiler-cli,core,forms,http,platform-browser,platform-browser-dynamic,platform-server,router,animations}@latest typescript@latest --save " **

Versions.

Angular version: 2.0.X Browser:Chrome Language:TypeScript Node (for AoT issues): node --version = 6.10.1

Repro steps.

when I run my app after updation I’m getting the following problem. I run my app using npm start and ng serve both.

The log given by the failure.

Module build failed: TypeError: Cannot read property ‘exclude’ of undefined

Desired functionality.

simply it have to compile but error occur during compilation.

Mention any other details that might be useful.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
newnewbcommented, Apr 16, 2017

Experiencing the same issue on windows.

Trying to update to Angular 4.

It was compiling fine on angular2 until I added

npm install @angular/common@latest @angular/compiler@latest @angular/compiler-cli@latest @angular/core@latest @angular/forms@latest @angular/http@latest @angular/platform-browser@latest @angular/platform-browser-dynamic@latest @angular/platform-server@latest @angular/router@latest @angular/animations@latest typescript@latest --save

Exact same error

ERROR in ./src/main.ts Module build failed: TypeError: Cannot read property 'exclude' of undefined at applyDefaults (C:\Users\user\Documents\test\final\node_modules\awesome-typescript-loader\src\instance.ts:266:72) at Object.ensureInstance (C:\Users\user\Documents\test\final\node_modules\awesome-typescript-loader\src\instance.ts:145:5) at compiler (C:\Users\user\Documents\test\final\node_modules\awesome-typescript-loader\src\index.ts:37:20) at Object.loader (C:\Users\user\Documents\test\final\node_modules\awesome-typescript-loader\src\index.ts:18:18) @ multi main

0reactions
angular-automatic-lock-bot[bot]commented, Sep 7, 2019

This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot read property 'exclude' of undefined #190 - GitHub
The full error: Module build failed: TypeError: Cannot read property 'exclude' of undefined at applyDefaults (.
Read more >
Module build failed: TypeError: Cannot read property 'exclude ...
No not yet, but it's basically versioning issue. The problem will get solve if I convert my typescript version to less than or...
Read more >
s-panferov/awesome-typescript-loader - Gitter
ERROR in ./src/polyfills.browser.ts Module build failed: TypeError: Cannot read property 'exclude' of undefined at applyDefaults ...
Read more >
Module Build Failed: Typeerror: Cannot Read Property ...
If I don't use atl and bundle using the compiled js everything gets read in TypeError: Cannot read property 'exclude' of undefined at...
Read more >
Installing Node and the Angular and Firebase Demo Application
... Cannot read property 'exclude' of undefined at applyDefaults (C:\DEV\Mosh\final-project\node_modules\awesome-typescript-loader\src\instance.ts:266:72)
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found