'How to resolve 'Error: unreachable' in Angular 11

I am new to Angular and I am obtaining the above error in the Console of the developer tools window. When I extend the Angular frames you will see the following. The main.ts file where the error should reside is given by:

import { enableProdMode } from '@angular/core';
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';

import { AppModule } from './app/app.module';
import { environment } from './environments/environment';

if (environment.production) {
  enableProdMode();
}

platformBrowserDynamic().bootstrapModule(AppModule)
  .catch(err => console.error(err));

The app.module simply bootstraps with the AppComponent. I know the error is simply caught in the last line of the main.ts file and that all of the above is probably too little information to find the cause of the error. If this is indeed the case, then I am also wondering how to obtain more information surrounding the error, since the Console is providing very little.

I already got a bunch of applications working but even after heavily searching the web I could not figure out what to do about this error. According to Visual Studio Code, I do not have any syntax errors.

Does anyone have a clue what could be going wrong?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source