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

206
Views
La secuencia de comandos asíncrona en React/Next js no se ejecuta/aparece

Estoy tratando de agregar anuncios de Amazon Native Shopping a mi sitio web, pero el anuncio nunca aparece. Su código se ve así:

 <div id="amzn-assoc-ad-944106c8-19e7-4323-aa3f-71c0cef0998b"></div> <script async src="//z-na.amazon-adsystem.com/widgets/onejs?MarketPlace=US&adInstanceId=944106c8-19e7-4323-aa3f-71c0cef0998b"></script>

Hasta ahora, he intentado agregar el script con Nextjs <Script> , agregar <script> dentro de Nextjs <Head> y crear el script en un gancho useEffect como este:

 useEffect(() => { const script = document.createElement("script"); script.src = "//z-na.amazon-adsystem.com/widgets/onejs?MarketPlace=US&adInstanceId=944106c8-19e7-4323-aa3f-71c0cef0998b"; script.async = true; document.body.appendChild(script); }, []);

También ofrecen un script sincrónico, pero este siempre se muestra en la parte inferior de la página.

Cualquiera

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!