Skip to content

Instantly share code, notes, and snippets.

@NyaGarcia
Created May 20, 2022 10:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save NyaGarcia/1178db3ff0af5ec507c34d5e515b1a5d to your computer and use it in GitHub Desktop.
Save NyaGarcia/1178db3ff0af5ec507c34d5e515b1a5d to your computer and use it in GitHub Desktop.
Creating the Pokemon list
<div class="card-container">
<mat-card
*ngFor="let pokemon of pokemon$ | async"
(click)="selectPokemon(pokemon)"
>
<mat-card-header>
<mat-card-title>{{ pokemon.name }}</mat-card-title>
<mat-card-subtitle>{{ pokemon.type }} type</mat-card-subtitle>
</mat-card-header>
<img mat-card-image [src]="pokemon.imgUrl" alt="Photo of a Pokemon" />
<mat-card-content>
<p>
{{ pokemon.description }}
</p>
</mat-card-content>
</mat-card>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment