V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
BUappend

移动端,网页埋点

  •  
  •   BUappend · Dec 9, 2020 · 2344 views
    This topic created in 1976 days ago, the information mentioned may be changed or developed.

    突然发现,移动端木有 mousedown 的事件,只有 click 事件,但是有 300ms,所以移动端网页在 click 发送埋点是不可能的了,在本页面更换路径的时候,肯定会 abort 掉的,但是在 touchstart 发送也不行,因为可能会拖动啊,请问这种情况应该怎么做埋点呢?或者能模拟 mousedown 的效果吗?

    2 replies    2020-12-21 14:53:52 +08:00
    buhi
        1
    buhi  
       Dec 9, 2020
    用 pointerdown
    手机端 safari 不管用, 需要用 polyfill : https://github.com/jquery/PEP
    tutou
        2
    tutou  
       Dec 21, 2020
    不用 fastclick 解决 300ms 延迟?
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   4700 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 32ms · UTC 01:02 · PVG 09:02 · LAX 18:02 · JFK 21:02
    ♥ Do have faith in what you're doing.