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

61
Views
¿Dónde se encuentran los datos en un objeto?

Para tomar datos de un formulario, uso new FormData . Consulte el código de ejemplo a continuación. Haga clic en enviar y los datos se mostrarán en la consola.

Hay una matriz de datos en el primer registro (usando el operador de propagación) y hay un objeto de datos en el segundo registro, pero cuando busco los datos en el objeto en el registro de la consola no puedo encontrarlo. Quiero saber dónde se encuentran los datos en Object.

 const form = document.querySelector('form'); form.addEventListener('submit', function(e){ e.preventDefault(); const data = new FormData(form) // first log is an array console.log([...data]) // second log is an Object console.log(data) })
 <body> <form> <label >input1</label> <input name="input1" type="text" value='test1' /> <label >input1</label> <input name="input1" type="text" value='test2' /> <button type="submit">Submit</button> </form> </body>

about 4 years ago · Juan Pablo Isaza
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!