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

185
Views
React - Elements in a list incorrectly receive hover state when a sibling is removed as result of a touch event

I've logged a bug for this over in the React repo but it seems to have gone stale.

Essentially what I'm seeing is that if you render a list, e.g.:

return (
  <div>{items.map(item => <ItemDisplay key={item} item={item} />)}</div>
)

And then you tap an item to delete it, once that element has been removed from the DOM, its sibling receives a hover state.

I suspect what happens is that the actual element you want to remove isn't removed at all, but is just repurposed to display the other elements. So technically the element is still "hovered". But in reality it should be removed.

You can reproduce the example here by opening it with a touch device ( e.g. your phone ).

about 4 years ago · Santiago Gelvez
1 answers
Answer question

0

Try using react-app-polyfill: "This package includes polyfills for various browsers. It includes minimum requirements and commonly used language features used by Create React App projects."

npm install react-app-polyfill

And this have to be the first line in src/index.js

import 'react-app-polyfill/stable';

I tried with firefox and chrome from my mobile and everything is working fine..

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