From 1ab2ebc719544973d322930e074249e8170446cb Mon Sep 17 00:00:00 2001 From: Kapunahele Wong Date: Tue, 19 Nov 2019 16:06:23 -0500 Subject: [PATCH] docs: edit EventEmitter name in styleguide (#33923) Fixes #33890 PR Close #33923 --- .../heroes/shared/hero-button/hero-button.component.avoid.ts | 4 ++-- .../app/heroes/shared/hero-button/hero-button.component.ts | 2 +- .../heroes/shared/hero-button/hero-button.component.avoid.ts | 2 +- .../app/heroes/shared/hero-button/hero-button.component.ts | 2 +- aio/content/guide/styleguide.md | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/aio/content/examples/styleguide/src/05-12/app/heroes/shared/hero-button/hero-button.component.avoid.ts b/aio/content/examples/styleguide/src/05-12/app/heroes/shared/hero-button/hero-button.component.avoid.ts index 8f393ddd32..50538311e9 100644 --- a/aio/content/examples/styleguide/src/05-12/app/heroes/shared/hero-button/hero-button.component.avoid.ts +++ b/aio/content/examples/styleguide/src/05-12/app/heroes/shared/hero-button/hero-button.component.avoid.ts @@ -10,11 +10,11 @@ import { Component, EventEmitter } from '@angular/core'; 'label' ], outputs: [ - 'change' + 'heroChange' ] }) export class HeroButtonComponent { - change = new EventEmitter(); + heroChange = new EventEmitter(); label: string; } // #enddocregion example diff --git a/aio/content/examples/styleguide/src/05-12/app/heroes/shared/hero-button/hero-button.component.ts b/aio/content/examples/styleguide/src/05-12/app/heroes/shared/hero-button/hero-button.component.ts index b299740765..cd7414d7be 100644 --- a/aio/content/examples/styleguide/src/05-12/app/heroes/shared/hero-button/hero-button.component.ts +++ b/aio/content/examples/styleguide/src/05-12/app/heroes/shared/hero-button/hero-button.component.ts @@ -7,7 +7,7 @@ import { Component, EventEmitter, Input, Output } from '@angular/core'; template: `` }) export class HeroButtonComponent { - @Output() change = new EventEmitter(); + @Output() heroChange = new EventEmitter(); @Input() label: string; } // #enddocregion example diff --git a/aio/content/examples/styleguide/src/05-13/app/heroes/shared/hero-button/hero-button.component.avoid.ts b/aio/content/examples/styleguide/src/05-13/app/heroes/shared/hero-button/hero-button.component.avoid.ts index 4e67a14113..8b565175be 100644 --- a/aio/content/examples/styleguide/src/05-13/app/heroes/shared/hero-button/hero-button.component.avoid.ts +++ b/aio/content/examples/styleguide/src/05-13/app/heroes/shared/hero-button/hero-button.component.avoid.ts @@ -8,7 +8,7 @@ import { Component, EventEmitter, Input, Output } from '@angular/core'; }) export class HeroButtonComponent { // Pointless aliases - @Output('changeEvent') change = new EventEmitter(); + @Output('heroChangeEvent') heroChange = new EventEmitter(); @Input('labelAttribute') label: string; } // #enddocregion example diff --git a/aio/content/examples/styleguide/src/05-13/app/heroes/shared/hero-button/hero-button.component.ts b/aio/content/examples/styleguide/src/05-13/app/heroes/shared/hero-button/hero-button.component.ts index af6e7d46b7..f71aa71cfa 100644 --- a/aio/content/examples/styleguide/src/05-13/app/heroes/shared/hero-button/hero-button.component.ts +++ b/aio/content/examples/styleguide/src/05-13/app/heroes/shared/hero-button/hero-button.component.ts @@ -8,7 +8,7 @@ import { Component, EventEmitter, Input, Output } from '@angular/core'; }) export class HeroButtonComponent { // No aliases - @Output() change = new EventEmitter(); + @Output() heroChange = new EventEmitter(); @Input() label: string; } // #enddocregion example diff --git a/aio/content/guide/styleguide.md b/aio/content/guide/styleguide.md index eabe896ff6..0eee96de34 100644 --- a/aio/content/guide/styleguide.md +++ b/aio/content/guide/styleguide.md @@ -2972,7 +2972,7 @@ in those editors that support it; it won't help with CSS styles. **Why?** If you ever need to rename the property or event name associated with -`@Input` or `@Output`, you can modify it in a single place. +`@Input()` or `@Output()`, you can modify it in a single place.