If you set your root component (usually the AppComponent) to only contain the
< router-outlet >, you can easily configure your routing setup. Just make sure your default route points to a different component, like this:
const routes: Routes = [
{ path: '', component: MyComponent },
{ path: 'another', component: AnotherComponent }
];
Make sure the default route is pointing to a specific component, not the AppComponent itself.
Check out this plunker for an example: https://plnkr.co/edit/CvztzcejGvXogmx0kmjL?p=preview
I hope this explanation clears things up for you.