• 请不要在回答技术问题时复制粘贴 AI 生成的内容
ayang23
V2EX  ›  程序员

如何在Mac里调试网页在 iPhone 的显示效果?

  •  
  •   ayang23 ·
    ayang23 · Jun 18, 2013 · 7364 views
    This topic created in 4755 days ago, the information mentioned may be changed or developed.
    用手机调试嫌麻烦,要是能在safari或chrome里调试就好多了
    16 replies    1970-01-01 08:00:00 +08:00
    wenbinwu
        1
    wenbinwu  
       Jun 18, 2013
    xcode
    little_cup
        2
    little_cup  
       Jun 18, 2013
    xcode+1
    ayang23
        3
    ayang23  
    OP
       Jun 18, 2013
    @wenbinwu 刚试了下可以,不过xcode开模拟器必须新建一个ios项目吗?还有就是这个方法能不能用html/css检查器?三指触摸才能滚动也不是很爽。
    wenbinwu
        4
    wenbinwu  
       Jun 18, 2013
    @ayang23 这个我没深入研究过,只是用来看样子:p 看看别人怎么说
    lanceli
        5
    lanceli  
       Jun 18, 2013
    ayang23
        6
    ayang23  
    OP
       Jun 18, 2013
    @lanceli 这个很爽,thanks
    romoo
        7
    romoo  
       Jun 18, 2013
    Chrome 的 Developer Tools,把 User Agent 改成 iOS。
    spark
        8
    spark  
       Jun 18, 2013
    Safari +1
    Sivan
        9
    Sivan  
       Jun 18, 2013
    感觉直接用手机的 Safari 调试挺方便的啊,可以直接在开发工具改手机中的效果。
    luin
        10
    luin  
       Jun 18, 2013
    在iOS Simulator里打开Safari,然后在OS X的Safari中可以打开inspector调试
    ayang23
        11
    ayang23  
    OP
       Jun 18, 2013
    @Sivan
    @luin 用了一下,这个果然很方便,谢谢
    kfll
        12
    kfll  
       Jun 18, 2013 via iPhone
    iOS 6
    Safari Mobile 设置中的 Web 调试器 打开
    连上 Mountain Lion
    Safari 开发菜单中能看到自己的手机

    另外 Chrome 能设置页面 viewport 宽高
    xiaogui
        13
    xiaogui  
       Jun 18, 2013
    @ayang23 搜下 opera mobile emulator
    FuryBean
        14
    FuryBean  
       Jun 18, 2013
    @ayang23 开模拟器只需要在XCode的Dock图标上右键->Open Develper Tools->iOS Simulator,不需要新建项目。
    ayang23
        15
    ayang23  
    OP
       Jun 18, 2013
    @kfll
    @xiaogui
    @FuryBean 多谢,你们给的方法都很给力,另外,我查到可以给ios simulator这个程序建一个链接,直接打开。
    hzlzh
        16
    hzlzh  
    PRO
       Jun 18, 2013
    除了楼上的模拟器方法,也可以试试safari的联动真机调试。
    http://zlz.im/how-to-use-ios-safari-remote-debug-tools/
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3744 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 58ms · UTC 00:46 · PVG 08:46 · LAX 17:46 · JFK 20:46
    ♥ Do have faith in what you're doing.