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

193
Views
Cambie el método de matriz para iniciar y detener el tiempo a secuencialmente

Solo necesito cambiar el método de matriz a secuencialmente para iniciar y detener el tiempo. necesito ser asi:

inicio"palabra1, "inicio"palabra2", inicio"palabra3", inicio"palabra4"

 const timings = [ { start: 0, stop: 1000 }, { start: 1000, stop: 2000 }, { start: 2000, stop: 5000 }, { start: 5000, stop: 10000 } ] const durations = timings.map(timing => timing.stop - timing.start ) const container = document.body; const childArray = [...container.children]; // To use array methods childArray.forEach((el, i) => { el.onclick = () => { el.classList.toggle('highlight'); nextWord = childArray[i + 1]; if (!nextWord) return // Last word setTimeout(() => { el.classList.toggle('highlight'); nextWord.click(); }, durations[i]) } })
 .highlight { background-color: yellow; }
 <!DOCTYPE html> <html> <body> <span>word1</span> <span>word2</span> <span>word3</span> <span>word4</span> </body> </html>

about 4 years ago · Santiago Gelvez
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!