Skip to content

Simplify stock.html for legibility #22

@dkromp

Description

@dkromp

Simplify from:

<!-- File: chapter11/directive-broken-reference/stock.html -->
<div class="stock-dash">
  Name:
  <span class="stock-name"
        ng-bind="stockData.name">
  </span>
  Price:
  <span class="stock-price"
        ng-bind="stockData.price | currency">
  </span>
  Percentage Change:
  <span class="stock-change"
        ng-bind="getChange(stockData) + '%'">
  </span>

  <button ng-click="changeStock()">
    Change Stock in Directive
  </button>
</div>

to:

<!-- File: chapter11/directive-broken-reference/stock.html -->
<div>
  Name: {{stockData.name}}
  Price: {{stockData.price | currency}}
  Percentage Change: {{getChange(stockData) + '%'}}

  <button ng-click="changeStock()">
    Change Stock in Directive
  </button>
</div>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions