app-routing.module.ts
662 Bytes
import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
import { InformacionComponent } from './informacion/informacion.component';
import { MainComponent } from './main/main.component';
import { BusquedaComponent } from './busqueda/busqueda.component';
const routes: Routes = [
{ path: '', component : MainComponent },
{ path: 'informacion/:id', component: InformacionComponent },
{ path: 'busqueda/:search', component: BusquedaComponent }
];
/* { path: '**', component: PageNotFoundComponent } */
@NgModule({
imports: [RouterModule.forRoot(routes)],
exports: [RouterModule]
})
export class AppRoutingModule { }