Better-scroll is used on the PC side, the mouse can’t achieve scrolling solution

I only found out after consulting the official documents, I need to add an attribute.

mouseWheel: true
const bScroll=new BScroll(document.querySelector('.wrapper'),{
    
    
    probeType:3,
    mouseWheel: true
  });
  bScroll.on("scroll",(position)=>{
    
    
    console.log(position);
  })

Guess you like

Origin blog.csdn.net/dwjdj/article/details/111752887