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

97
Vistas
obteniendo datos de la api del mapa

Estoy usando mapbox e intento obtener algunos datos de esta API: JSON

 async function getLocation(updateSource) { // Make a GET request to the API and return the location of the ISS. try { const response = await fetch( 'https://api.wheretheiss.at/v1/satellites/25544', { method: 'GET' } ); const { latitude, longitude } = await response.json(); // Fly the map to the location. map.flyTo({ center: [longitude, latitude], speed: 0.5 }); // Return the location of the ISS as GeoJSON. return { 'type': 'FeatureCollection', 'features': [ { 'type': 'Feature', 'geometry': { 'type': 'Point', 'coordinates': [longitude, latitude] } } ] }; } catch (err) { // If the updateSource interval is defined, clear the interval to stop updating the source. if (updateSource) clearInterval(updateSource); throw new Error(err); } } });

así que cuando traté de obtener el enlace JSON, ¡obtuve un error! ¿Esto se debe a que el JSON que quiero usar tiene algunos problemas? Esta es la base de código: https://jsfiddle.net/dhap8430

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