Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

116
Vistas
how to properly console this shiba-inu price
async function getPrice () {
 //console.log("waiting");
const price = await  promise.all([axios.get('https://api.coingecko.com/api/v3/simple/price?ids=shiba-inu&vs_currencies=usd'),axios.get('https://api.coingecko.com/api/v3/simple/price?ids=dogecoin&vs_currencies=usd')]).then(results =>{
                 return results[0].data.shiba-inu.usd / results[1].data.dogecoin.usd;}).then(pricedata =>{
                 return pricedata;
    });         
  return price ;
};

the json file from : https://api.coingecko.com/api/v3/simple/price?ids=shiba-inu&vs_currencies=usd contains :

{
  "shiba-inu": {
    "usd": 0.00002847
  }
}

this is the error:

return results[0].data.shiba-inu.usd / results[1].data.dogecoin.usd;}).then(pricedata =>{

ReferenceError: inu is not defined.

I don't know how to properly get the shiba-inu price , I have tried to put it between () or ''. the code is runnig well my only problem is with this composed name(shiba-inu) if I try tether or something else it goes well (replacing api and results[0].data.tether.usd)

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda