Fixed Image Source Link.

Fixed Image Source Link, Changed Link because old link is expired, and added new link with Sprites.
This commit is contained in:
Omar Ashraf 2021-04-18 13:57:20 +03:00 committed by GitHub
parent 4dd2f9dd57
commit 5ac19e4677
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -47,7 +47,7 @@ const createPokemonCard = (pokemon) => {
const pokemonInnerHTML = ` const pokemonInnerHTML = `
<div class="img-container"> <div class="img-container">
<img src="https://pokeres.bastionbot.org/images/pokemon/${pokemon.id}.png" alt=""> <img src="https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/${pokemon.id}.png"" alt="${name}">
</div> </div>
<div class="info"> <div class="info">
<span class="number">#${id}</span> <span class="number">#${id}</span>
@ -61,4 +61,4 @@ const createPokemonCard = (pokemon) => {
poke_container.appendChild(pokemonEl) poke_container.appendChild(pokemonEl)
} }
fetchPokemons() fetchPokemons()