How do I restore events for a single DOM element when global default events are blocked?

the global is written in this way, preventing document scrolling events. The advantage of this is that when Wechat opens the web page, the drop-down screen will not appear url and X5 kernel prompts.

$(document).on("touchmove", function(e) {
    e.preventDefault();
});

but I have a requirement, which is to scroll the list in the box in the center of the screen. What can I do without letting the screen drop down and ensure that the box scrolls properly at the same time?

Mar.19,2021

add events to the box you need to scroll and prevent events from propagating e.stopPropagation ()


you write overflow directly in the current box

Menu