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

202
Vistas
Trying to get a react-app that's not mine to work which cannot find a localhost url

I have a react app that isn't mine (a former employee) and I'm still quite new to react. I need to get the app to work so it retrieves data from a SQL database. At the moment the app can't find a request URL from itself called http://localhost//FleetManagement//Api/Default.aspx?method=GetCustomers

The react app gives the following error:

enter image description here

Or in text:

SyntaxError: Unexpected end of JSON input
(anonymous function)
C:/CodeRacvsolar/react-app/src/App.tsx:201
  198 | 
  199 | api.getCustomers(
  200 |   (req: XMLHttpRequest) => {
> 201 |     let getCustomersResponse: interfaces.GetCustomersResponse = JSON.parse(req.responseText);
  202 | ^
  203 |     this.setState({
  204 |       data: getCustomersResponse,
View compiled

XMLHttpRequest.req.onreadystatechange
C:/CodeRacvsolar/react-app/src/api/api.tsx:54
  51 | 
  52 |        if (req.readyState === XMLHttpRequest.DONE) { 
  53 |            if (onComplete) {
> 54 |                onComplete(req)
  55 | ^          }
  56 |        }
  57 |        
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