parent
240a0dc457
commit
ac8b87eb5e
|
@ -578,7 +578,7 @@ code-example(format="", language="html").
|
||||||
Now imagine a parent component that listens for that event with an Event Binding.
|
Now imagine a parent component that listens for that event with an Event Binding.
|
||||||
+makeExample('template-syntax/ts/app/app.component.html', 'event-binding-to-component')(format=".")
|
+makeExample('template-syntax/ts/app/app.component.html', 'event-binding-to-component')(format=".")
|
||||||
:marked
|
:marked
|
||||||
The event binding surfaces the *hero-to-delete* emitted by `HeroDetail` to the expression via the `$hero` variable.
|
The event binding surfaces the *hero-to-delete* emitted by `HeroDetail` to the expression via the `$event` variable.
|
||||||
We pass it along to the parent `onHeroDeleted()` method.
|
We pass it along to the parent `onHeroDeleted()` method.
|
||||||
That method presumably knows how to delete the hero.
|
That method presumably knows how to delete the hero.
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue