JSON Spacing Key, "." and Main Letter

Asked

Viewed 79 times

-2

inserir a descrição da imagem aqui

Hello people, I would like to know how I can get the values of HP, Sp. Attack and Sp. Defense in Javascript?? the values below work but the quoted ones do not =[

  console.log(pokedata[id].base.Attack);
  console.log(pokedata[id].base.Defense);
  console.log(pokedata[id].base.Speed);
  
  • Consider pasting the code instead of posting the JSON print.

1 answer

0


  • thank you Joao!! I had already tested this method and it was not working but now that I copied and pasted your answer worked!!. will understand rsrs

Browser other questions tagged

You are not signed in. Login or sign up in order to post.