zehua
V2EX  ›  iOS

被一个问题卡了好多天了,求教一下!

  •  
  •   zehua · May 17, 2023 · 2507 views
    This topic created in 1115 days ago, the information mentioned may be changed or developed.
    ios 里面用到了 wkwebview ,想通过 Mac 的 safari 调试里面的 js 的,按照教程是需要打开手机里面 safari 的 enable web inspector ,可是模拟器 ios 没有这个选项,请教一下这是为啥? ios16.4 macOS13 。
    Supplement 1  ·  May 17, 2023

    按照 https://webkit.org/blog/13936/enabling-the-inspection-of-web-content-in-apps/ 文档的说法:

    #To enable remote inspection on an iOS device:

    • open the Settings app
    • go to Safari
    • scroll down to Advanced
    • enable the Web Inspector toggle

    我的模拟器里面没有:enable the Web Inspector toggle

    4 replies    2023-05-17 23:50:57 +08:00
    xtinput
        1
    xtinput  
       May 17, 2023   ❤️ 1
    16.4 之后有个 isInspectable 属性
    zehua
        3
    zehua  
    OP
       May 17, 2023
    @xtinput 设置了也不行,主要是 safari 的设置里面不显示 web inspector 这个开关。
    zehua
        4
    zehua  
    OP
       May 17, 2023
    @xtinput 重启后可以了,感谢🙏
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2794 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 43ms · UTC 10:09 · PVG 18:09 · LAX 03:09 · JFK 06:09
    ♥ Do have faith in what you're doing.