Hacker News new | past | comments | ask | show | jobs | submit login

Agreed, it's a much harder problem to get right than it looks on the surface "sure I can add drag & drop easily!". Like a lot of things in software...



To me it's very interesting to see how many applications completely forgot that you might want to use a scroll wheel during a drag and drop. I don't think that even works half the time...


Yeah, I can attest to this. It sounds easy at first, but suddenly you need to handle items inside virtual lists (e.g., react-window), scrolling, data updating while dragging, ...


You can add drag and drop quite easily if you use a library for it.


That’s exactly what you think going in...that’s the point I’m making.

No one is hand rolling drag and drop these days.

There’s a lot of complexity implementing drag and drop both visually and binding stuff to events. It’s messy and finicky. Unless your usecase is very simple.


To add to sibling's point, many drag-drop libraries work great on a bare demo website with nothing else to worry about.

Once you start trying to add it to your frontend with other complex features already there, you're back having to reason about the core of drag-and-drop and essentially solving it yourself to parse the library's code. In my experience I've had to modify library code to handle my requirements most of the time because it did not play well in a complex environment.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: