style(docs-infra): fix docs examples for tslint rule import-spacing (#38143)

This commit updates the docs examples to be compatible with the
`import-spacing` tslint rule.

This is in preparation of updating the docs examples `tslint.json` to
match the one generated for new Angular CLI apps in a future commit.

PR Close #38143
This commit is contained in:
George Kalpakas
2020-07-30 13:03:09 +03:00
committed by Michael Prentice
parent b88abd81c8
commit c980caecac
201 changed files with 634 additions and 636 deletions

View File

@ -1,4 +1,4 @@
import { NgModule } from '@angular/core';
import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
export const routes: Routes = [

View File

@ -1,7 +1,7 @@
import { NgModule } from '@angular/core';
import { RouterModule } from '@angular/router';
import { NgModule } from '@angular/core';
import { RouterModule } from '@angular/router';
import { ContactComponent } from './contact.component';
import { ContactComponent } from './contact.component';
const routes = [
{ path: 'contact', component: ContactComponent}

View File

@ -1,9 +1,9 @@
// Exact copy except import UserService from greeting
import { Component, OnInit } from '@angular/core';
import { Component, OnInit } from '@angular/core';
import { FormBuilder, Validators } from '@angular/forms';
import { Contact, ContactService } from './contact.service';
import { UserService } from '../greeting/user.service';
import { UserService } from '../greeting/user.service';
@Component({
selector: 'app-contact',

View File

@ -1,9 +1,9 @@
import { NgModule } from '@angular/core';
import { SharedModule } from '../shared/shared.module';
import { NgModule } from '@angular/core';
import { SharedModule } from '../shared/shared.module';
import { ReactiveFormsModule } from '@angular/forms';
import { ContactComponent } from './contact.component';
import { ContactService } from './contact.service';
import { ContactComponent } from './contact.component';
import { ContactService } from './contact.service';
import { ContactRoutingModule } from './contact-routing.module';
@NgModule({

View File

@ -1,7 +1,7 @@
import { Injectable, OnDestroy } from '@angular/core';
import { Observable, of } from 'rxjs';
import { delay } from 'rxjs/operators';
import { delay } from 'rxjs/operators';
export class Contact {
constructor(public id: number, public name: string) { }

View File

@ -1,8 +1,8 @@
import { Component, OnInit } from '@angular/core';
import { ActivatedRoute } from '@angular/router';
import { ActivatedRoute } from '@angular/router';
import { Customer,
CustomersService } from './customers.service';
CustomersService } from './customers.service';
@Component({
template: `

View File

@ -1,9 +1,9 @@
import { NgModule } from '@angular/core';
import { NgModule } from '@angular/core';
import { Routes,
RouterModule } from '@angular/router';
import { CustomersComponent } from './customers.component';
import { CustomersListComponent } from './customers-list.component';
import { CustomersComponent } from './customers.component';
import { CustomersListComponent } from './customers-list.component';
import { CustomersDetailComponent } from './customers-detail.component';
const routes: Routes = [

View File

@ -1,4 +1,4 @@
import { Component } from '@angular/core';
import { Component } from '@angular/core';
import { CustomersService } from './customers.service';
import { UserService } from '../greeting/user.service';

View File

@ -1,12 +1,12 @@
import { NgModule } from '@angular/core';
import { NgModule } from '@angular/core';
import { SharedModule } from '../shared/shared.module';
import { SharedModule } from '../shared/shared.module';
import { CustomersComponent } from './customers.component';
import { CustomersComponent } from './customers.component';
import { CustomersDetailComponent } from './customers-detail.component';
import { CustomersListComponent } from './customers-list.component';
import { CustomersRoutingModule } from './customers-routing.module';
import { CustomersService } from './customers.service';
import { CustomersListComponent } from './customers-list.component';
import { CustomersRoutingModule } from './customers-routing.module';
import { CustomersService } from './customers.service';
@NgModule({

View File

@ -1,7 +1,7 @@
import { Injectable, OnDestroy } from '@angular/core';
import { Observable, of } from 'rxjs';
import { delay } from 'rxjs/operators';
import { delay } from 'rxjs/operators';
export class Customer {
constructor(public id: number, public name: string) { }

View File

@ -1,5 +1,5 @@
import { Component, Input } from '@angular/core';
import { UserService } from '../greeting/user.service';
import { UserService } from '../greeting/user.service';
@Component({
selector: 'app-greeting',

View File

@ -1,8 +1,8 @@
import { Component, OnInit } from '@angular/core';
import { ActivatedRoute } from '@angular/router';
import { ActivatedRoute } from '@angular/router';
import { Item,
ItemService } from './items.service';
ItemService } from './items.service';
@Component({
template: `

View File

@ -1,8 +1,7 @@
import { Component, OnInit } from '@angular/core';
import { Observable }from 'rxjs';
import { Observable } from 'rxjs';
import { Item,
ItemService } from './items.service';
import { Item, ItemService } from './items.service';
@Component({
template: `

View File

@ -1,9 +1,9 @@
import { NgModule } from '@angular/core';
import { NgModule } from '@angular/core';
import { Routes,
RouterModule } from '@angular/router';
RouterModule } from '@angular/router';
import { ItemsListComponent } from './items-list.component';
import { ItemsDetailComponent } from './items-detail.component';
import { ItemsListComponent } from './items-list.component';
import { ItemsDetailComponent } from './items-detail.component';
const routes: Routes = [
{ path: '', redirectTo: 'list', pathMatch: 'full'},

View File

@ -1,11 +1,11 @@
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { ItemsComponent } from './items.component';
import { ItemsListComponent } from './items-list.component';
import { ItemsDetailComponent } from './items-detail.component';
import { ItemService } from './items.service';
import { ItemsRoutingModule } from './items-routing.module';
import { ItemsListComponent } from './items-list.component';
import { ItemsDetailComponent } from './items-detail.component';
import { ItemService } from './items.service';
import { ItemsRoutingModule } from './items-routing.module';
@NgModule({
imports: [ CommonModule, ItemsRoutingModule ],

View File

@ -1,7 +1,7 @@
import { Injectable, OnDestroy } from '@angular/core';
import { Observable, of } from 'rxjs';
import { delay } from 'rxjs/operators';
import { delay } from 'rxjs/operators';
export class Item {
constructor(public id: number, public name: string) { }

View File

@ -1,9 +1,9 @@
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { AwesomePipe } from './awesome.pipe';
import { HighlightDirective } from './highlight.directive';
import { AwesomePipe } from './awesome.pipe';
import { HighlightDirective } from './highlight.directive';
@NgModule({
imports: [ CommonModule ],