'Error in console: ng.probe is not a function
Yesterday I updated Angular CLI and core to 8.0.0v. After that I successfully initialized a new app and ran it. Once the app was built and served on localhost:4200 I opened the console and there was an error:
ng.probe is not a function
I tried to research the issue, but there was no relevant info about it.
Actual result:
After ng serve / npm start there is an issue in the console:
Uncaught TypeError: ng.probe is not a function. Current console state Current angular state
Expected result:
No error in the console
Solution 1:[1]
If someone is looking for an alternative to:
ng.probe($0)
In Ivy, then please try this:
 ng.getComponent($0);
Found it here, https://juristr.com/blog/2019/09/debugging-angular-ivy-console/
Thought I'd add this here for completion.
Note about ng.getComponent: you must focus the component tag ( e.g. <app-my-component> ) in the developer tools elements so that it will be in $0. It doesn't search up the hierarchy for parent components ( like ng.probe does ).
Solution 2:[2]
If you're using Augury extension, disable or remove it. then, check the console. I've had the same issue and I removed the Augury.
Augury is having different set of debugging APIs, that's why that error occur.
Solution 3:[3]
Yes, augury assumes angular dev mode is active if window.ng exists, but ivy doesn't export probe right now
 I have augury but after I disable the extension there is no error anymore.
I have augury but after I disable the extension there is no error anymore.
Solution 4:[4]
You could also run without Ivy with this in your tsconfig.app.json
"angularCompilerOptions": { "enableIvy": false }
Solution 5:[5]
This is not exactly related to this question, but googling led me here. So, I am leaving the solution to my problem here in hopes that it will help others who face the same problem.
I was getting ng.probe not a function error when I created a angular project using dotnet sdk(version 5.0.300) and ran it locally. The project was using @angular/core v8.2.12, and @angular/cli v8.3.29.
I was able to solve the problem by update these packages using -
ng update @angular/core@8 @angular/cli@8
or
npm run ng update @angular/core@8 @angular/cli@8
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source | 
|---|---|
| Solution 1 | |
| Solution 2 | |
| Solution 3 | Mrinal Jain | 
| Solution 4 | BuZZ-dEE | 
| Solution 5 | th1rdey3 | 
