Currently, I am utilizing angular2 Final version for my development tasks.
Within my project, I have established 3 distinct modules:
- AppModule
- ProjectModule
- DesignerModule
In the past, I solely had AppModule which integrated the following RoutingModule successfully:
import {NgModule} from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
import {ProjectManagerComponent} from './project-manager/project-manager.component';
import {DesignerComponent} from './designer/designer.component';
const appRoutes: Routes = [
{path: '',redirectTo: 'project-manager',pathMatch: 'full'},
{ path: 'project-manager', component: ProjectManagerComponent },
{ path: 'designer/:id', component:DesignerComponent }
];
@NgModule({
imports:[RouterModule.forRoot(appRoutes)],
exports:[RouterModule]
})
export class AppRoutingModule { }
export const routingComponents=[ProjectManagerComponent,DesignerComponent]
However, recently I've segregated ProjectManager and Designer into separate NgModules. In these new modules, the components are contained within the declarations section.
I am curious to know if it's feasible to route to these newly created modules using the existing routing configuration or if modifications are necessary.
Currently facing issues as my routing functionality has ceased working.
Seeking insights or suggestions on this matter.