guides-source icon indicating copy to clipboard operation
guides-source copied to clipboard

Thought on quick start

Open samselikoff opened this issue 6 years ago • 0 comments

The first component we make is a <PeopleList />, but the main motivation for this is reuse (as the help text describes). But then we don't reuse the component.

What if the example was something like a <PersonCard>, so the user could see the component being reused?

The refactor would be

  <h2>List of Scientists</h2>

  <ul>
    {{#each @model as |scientist|}}
-     <li>{{scientist}}</li>
+     <PersonCard @person={{@scientist}} />
    {{/each}}
  </ul>

samselikoff avatar Oct 08 '19 03:10 samselikoff