Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

214
Views
Error de lanzamiento de reacción al usar ganchos sin prefijo de nombre de clase

Cuando uso ganchos sin prefijo de nombre de clase, arroja un error. Por favor ayúdame a arreglarlo

 import React, {Fragment,useState} from 'react'; function App (props) { const [x,updateX] = useState(1) /* throwing error without the - React class name, like - React.useState(value) */ return ( //same here <Fragment> <h2>This is app.js {x}</h2> </Fragment> ); } export default App;
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Según el código que proporcione aquí, el resultado esperado es This is app.js 1

que acabo de reproducir así,

 import React,{ Fragment, useState } from "react"; function App(props) { const [x,updateX] = useState(1) return ( <Fragment> <h2>This is app.js {x}</h2> </Fragment> ); } export default App;

¡Si aún enfrenta un error, probablemente necesite más contexto para resolverlo! La salida que obtuve ingrese la descripción de la imagen aquí

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!