Após seguir todo o passo a passo da aula 9 e utilizar a diretiva do Angular chamada router outlet está mostrando uma mensagem em vermelho no terminal com um erro e não consigo abrir o site ./src/app/app-routing.module.ts:11:23 - Error: Module parse failed: Unexpected token (11:23) File was processed with these loaders:
- ./node_modules/@angular-devkit/build-angular/src/babel/webpack-loader.js
- ./node_modules/@ngtools/webpack/src/ivy/index.js
You may need an additional loader to handle the result of these loaders.
| {
| path: 'home',
loadChildren: () = -import('./home/home.module').then((m) = -m.HomeModule),
| }, | ];
Error: src/app/app-routing.module.ts:3:25 - error TS2307: Cannot find module 'os' or its corresponding type declarations.
3 import { homedir } from 'os';
~~~~
Error: src/app/app-routing.module.ts:13:3 - error TS2322: Type 'number' is not assignable to type 'LoadChildren | undefined'.
13 loadChildren: ()=- import('./home/home.module').then((m) =- m. HomeModule),
~~~~~~~~~~~~
node_modules/@angular/router/router.d.ts:1970:5 1970 loadChildren?: LoadChildren;
~~~~~~~~~~~~
The expected type comes from property 'loadChildren' which is declared here on type 'Route'
Error: src/app/app-routing.module.ts:13:18 - error TS1109: Expression expected.
13 loadChildren: ()=- import('./home/home.module').then((m) =- m. HomeModule), ~
Error: src/app/app-routing.module.ts:13:56 - error TS2345: Argument of type 'number' is not assignable to parameter of type '((value: typeof import("C:/Users/samue/projetoelogroup/src/app/home/home.module")) => typeof import("C:/Users/samue/projetoelogroup/src/app/home/home.module") | PromiseLike<typeof import("C:/Users/samue/projetoelogroup/src/app/home/home.module")>) | null | undefined'.
13 loadChildren: ()=- import('./home/home.module').then((m) =- m. HomeModule),
~
Error: src/app/app-routing.module.ts:13:57 - error TS2304: Cannot find name 'm'.
13 loadChildren: ()=- import('./home/home.module').then((m) =- m. HomeModule), ~
Error: src/app/app-routing.module.ts:13:63 - error TS2304: Cannot find name 'm'.
13 loadChildren: ()=- import('./home/home.module').then((m) =- m. HomeModule), ~