Skip to content

Commit

Permalink
Made out-of-scope but reasonable edits
Browse files Browse the repository at this point in the history
  • Loading branch information
zachgarwood authored and lenoraporter committed Jul 19, 2020
1 parent 08ecc09 commit 56e62a8
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions guides/release/tutorial/autocomplete-component.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,7 @@ In this case we are passing, or "yielding", our filter data to the inner markup
</LinkTo>
</div>
<ListFilter
@filter={{action "filterByCity"}}
as |filteredResults|
>
<ListFilter @filter={{action "filterByCity"}} as |filteredResults|>
<ul class="results">
{{#each filteredResults as |rentalUnit|}}
<li><RentalListing @rental={{rentalUnit}} /></li>
Expand Down Expand Up @@ -102,7 +99,7 @@ export default class ListFilterComponent extends Component {

#### Filtering Data Based on Input

In the above example we use the `init` hook to seed our initial listings by calling the `filter` action with an empty value.
In the above example we use the `constructor` to seed our initial listings by calling the `filter` action with an empty value.
Our `handleFilterEntry` action calls a function called `filter` based on the `value` attribute set by the input helper.

The `filter` function is passed in by the calling object. This is a pattern known as closure actions.
Expand Down

0 comments on commit 56e62a8

Please sign in to comment.