anchor.diff:    what the user types back onto the screen.
     
     This time we'll both listen to an event and grab the user's input.
  -code-example(format="linenums" language="html" ).
  -  @Component({
  -    selector: 'key-up',
  -    template: `
  -      &lt;h4>Give me some keys!&lt;/h4>
  -      &lt;div>&lt;input (keyup)="onKey($event)">&lt;div>
  -      &lt;div>{{values}}&lt;/div>
  -    `
  -  })
  -  class KeyUpComponent {
  -    values='';
  -    onKey(event) {
  -      this.values += event.target.value + ' | ';  
  -    }
  -  }
  ++makeExample('template-syntax/ts/src/app/app.ts', 'key-up-component')
   :markdown
     Angular makes an event object available in the **`$event`** variable. The user data we want is in that variable somewhere.
     
  
positive.code:   
    Unfortunately, we can't use that name when we declare the variable with (#). 
    The browser forces all attribute and element names to lowercase, turning what would be `#newHero`
    into `#newhero`. We don't want a `newhero` variable name in our template expressions. 
    The Angular workaround is to spell the declaration in "snake case". When Angular encounters "#new-hero",it translates
    that to `newHero` for template expressions ... which is exactly what we want.
    
    ### **keyup.enter - a KeyEvent filter** 
    We'll add a hero name when the user clicks the "Add" button or hits the enter key. We ignore all other keys.
    If we bind to `(keyup)` our event handling expression hears every key event. We'd have to
    examine every `$event.keyCode` and respond only if the value is "Enter".
    
    Angular can filter the key events for us. Angular has a special syntax for keyboard events. 
    We can listen for just the "enter" key by binding to Angular's `keyup.enter` pseudo-event. 
    Then either the `keyup.enter` or the button click event
    can invoke the component's `addHero` method.
  
    ### **newHero refers to the `<input>` element**
    We can access the `newHero` variable from any sibling or child of the `<input>` element.
  
negative.code:   
    That local template variable is intriguing. It's clearly easer to get to the textbox with that
    variable than to go through the `$event` object. Maybe we can re-write our previous
    "key-up" example using the variable to acquire the user's' input. Let's give it a try.
  +makeExample('template-syntax/ts/src/app/app.ts', 'key-up2-component')
  :markdown
    That sure seems easier. 
    An especially nice aspect of this approach is that our component code gets clean data values from the view.
    It no longer requires knowledge of the `$event` and its structure.
  
  <a id="key-event"></a>
  .l-main-section
  :markdown
    ## Key event filtering (with `key.enter`)
    Perhaps we don't care about every keystroke. 
    We're only interested in the input box value when the user hits the "Enter" key. We'd like to ignore all other keys.
    When we bind to the `(keyup)` event, our event handling expression hears *every key stroke*. 
    We could filter the keys first, examining every `$event.keyCode`, and update the `values` property only if the key is "Enter".
    
    Angular can filter the key events for us. Angular has a special syntax for keyboard events. 
    We can listen for just the "Enter" key by binding to Angular's `keyup.enter` pseudo-event. 
    
    Only then do we update the component's `values` property ... 
    inside the event expression rather than in the component ... 
    because we can ... even if it is a dubious practice.
  +makeExample('template-syntax/ts/src/app/app.ts', 'key-up3-component')
  .alert.is-helpful
    :markdown
      We won't transfer the current state of the input box if the user mouses away or clicks
      elsewhere on the page. We only update the component's `values` property when the user presses "Enter"
      inside the input box.
  .l-main-section
  :markdown
    ## Put it all together
  