SHARE
TWEET

Untitled

a guest Jun 17th, 2019 57 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import { BrowserModule } from '@angular/platform-browser';
  2.  import { NgModule } from '@angular/core';
  3.  import { FormsModule } from '@angular/forms';
  4.  import { HttpModule } from '@angular/http';
  5.  import { Routes, RouterModule } from '@angular/router';
  6.  import { AppComponent } from './app.component';
  7.  import { HomeComponent } from './home/home.component';
  8.  import { UsersComponent } from './users/users.component';
  9.  import { ServersComponent } from './servers/servers.component';
  10.  import { UserComponent } from './users/user/user.component';
  11.  import { EditServerComponent } from './servers/edit-server/edit-server.component';
  12.  import { ServerComponent } from './servers/server/server.component';
  13.  import { ServersService } from './servers/servers.service';
  14.  
  15.      const appRoutes: Routes = [
  16.         { path: '', component: HomeComponent },
  17.         { path: 'users', component: UsersComponent },
  18.         { path: 'server', component: ServerComponent }
  19.         ];
  20.  
  21.  
  22.  @NgModule({
  23. declarations: [ AppComponent, HomeComponent, UsersComponent, ServersComponent, UserComponent, EditServerComponent, ServerComponent ],
  24. imports: [ BrowserModule, FormsModule, HttpModule, RouterModule.forRoot(appRoutes) ],
  25.      
  26. <ul class="nav nav-tabs">
  27. <li role="presentation" class="active"><a routerLink="/">Home</a></li>
  28. <li role="presentation"><a routerLink="/server">Servers</a></li>
  29. <li role="presentation"><a [routerLink]="['/users']">Users</a></li> </ul> </div>
  30.  </div>
  31. <div class="row">
  32. <div class="col-xs-12 col-sm-10 col-md-8 col-sm-offset-1 col-md-offset-2">
  33. <app-home></app-home>
  34. </div> </div>
  35. <div class="row"> <div class="col-xs-12 col-sm-10 col-md-8 col-sm-offset-1 col-md-offset-2">
  36. <app-users></app-users> </div> </div>
  37.  <div class="row"> <div class="col-xs-12 col-sm-10 col-md-8 col-sm-offset-1 col-md-offset-2"> <app-servers></app-servers> </div> </div>
  38.      
  39. <div class="col-xs-12 col-sm-4"> <app-edit-server></app-edit-server> <hr> <app-server></app-server> </div>
  40.      
  41. <div class="container"> <div class="row"> <div class="col-xs-12 col-sm-10 col-md-8 col-sm-offset-1 col-md-offset-2"> <ul class="nav nav-tabs"> <li role="presentation" class="active"><a routerLink="/">Home</a></li> <li role="presentation"><a routerLink="/server">Servers</a></li> <li role="presentation"><a [routerLink]="['/users']">Users</a></li> </ul> </div> </div>
  42. <div class="row">
  43. <div class="col-xs-12 col-sm-10 col-md-8 col-sm-offset-1 col-md-offset-2"> <router-outlet></router-outlet>
  44. </div> </div> </div>
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top