I'm learning Angular 6
.
I have designed my application structure in hierarchy form with following structure.
my_app
|- src
|- app
|- layout
|- admin-layout
|- admin-layout.module.ts
|- admin-layout.routing.ts
|- admin-layout.component.html
|- contacts
|- contact-list
|- contact-list.component.ts
|- contact-list.component.html
|- contacts.module.ts
|- transaction
|- amount-given
|- amount-given-list
|- amount-given-list.component.ts
|- amount-given-list.component.html
|- amount-given.module.ts
|- amount-given.routing.ts
|- amount-given.service.ts
|- transaction.module.ts
|- transaction.routing.ts
|- app.module.ts
|- app.component.html
|- app-routing.module.ts
The source code and demo illustration can be found here: https://stackblitz.com/edit/angular-wcglvr
<a routerLink="/dashboard">Dashboard</a>
is working from /transaction/amount-given/amount-given-list/
but not from /contacts/contact-list
.
Since source code is quite long and hierarchical, I have added demo illustration on stackblitz.