It's really strange what happened with this project. It was working perfectly fine yesterday, and I even left 'ng serve' running after finishing my work without any issues.
However, today when I tried to compile the app, I ran into problems due to TypeScript 3.7.2 features, even though I have version 3.7.3 globally and 3.8.3 locally in the Angular project. Additionally, I'm receiving a warning about async/await use in zone.js, despite not using async/await anywhere in my project yet - even though I've used it in previous Angular projects without issue.
The specific errors are:
WARNING: Zone.js does not support native async/await in ES2017.
and
Module parse failed: Unexpected token (17:38)
> const address = !!company?.address;
> if (company?.address) {
These errors appear consistently throughout the app. The app was generated just weeks ago using Angular CLI 9 with default tsconfig settings:
"module": "esnext",
"moduleResolution": "node",
"target": "esnext",
"lib": ["es2018", "dom"]
I believe the issue lies with how the project is being compiled rather than within the project itself. Unfortunately, I'm at a loss for where to look or what might be missing. Any help or suggestions would be greatly appreciated.
Edit:
I deleted the local project, copied it back from git, updated to Angular 10 using TypeScript 3.9.5, but encountered the same issues.