Advertisement
Guest User

Untitled

a guest
Oct 19th, 2019
159
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.72 KB | None | 0 0
  1. import React from 'react'
  2.  
  3. const PokeCard = ({pokemon}) => {
  4. return (
  5. <div className="card text-center mx-auto" style={{"maxWidth" : "18rem"}} key={pokemon.id}>
  6. <div className="card-header"><b>{pokemon.name}</b></div>
  7. <div className="card-body">
  8. <h6 className="card-subtitle mb-2 text-muted">Id: {pokemon.id}</h6>
  9. <h6 className="card-subtitle mb-2 text-muted">Height: {pokemon.height}</h6>
  10. <h6 className="card-subtitle mb-2 text-muted">Weight: {pokemon.weight}</h6>
  11. <img src={pokemon.sprites['front_default']} />
  12. <img src={pokemon.sprites['back_default']} />
  13. </div>
  14. </div>
  15. )
  16. };
  17.  
  18. export default PokeCard
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement