safari 调试移动端_使用Safari开发工具调试iPhone移动Web应用程序

本文介绍了如何利用Safari开发工具进行移动端Web应用程序的调试,帮助开发者解决iPhone上遇到的问题。
摘要由CSDN通过智能技术生成

safari 调试移动端

I was developing a mobile web application for work that scans a QR code to check someone in for a hiring event, and I wanted to make sure the data being decoded from the QR code was correct. I also wanted to make sure one of my key function’s conditional statements was being evaluated properly. I was able to do this easily on my laptop with the help of Google Chrome’s Console.

我正在开发一个用于工作的移动Web应用程序,该应用程序扫描QR码以检查某人是否有招聘事件,并且我想确保从QR码解码的数据是正确的。 我还想确保正确评估了我的关键函数的条件语句之一。 借助Google Chrome浏览器的控制台,我可以轻松地在笔记本电脑上执行此操作。

For those unfamiliar with Google Chrome’s Console, it’s an extremely helpful development tool where all you have to do is put debuggers, console logs, etc. in the parts of your code you want to debug.

对于那些不熟悉Google Chrome浏览器控制台的人来说,它是一个非常有用的开发工具,您要做的就是将调试器,控制台日志等放在要调试的代码部分中。

You run the program while the Console is open, and once the program hits the line of code that has the debugger, it pauses the program so you can test for variables and other important values within the scope of your function. For more information about Google Chrome’s Console, check out this link.

您可以在控制台打开的情况下运行该程序,并且一旦程序进入了带有调试器的代码行,它就会暂停该程序,以便您可以在函数范围内测试变量和其他重要值。 有关Google Chrome浏览器控制台的更多信息,请查看此链接

Unfortunately, Google Chrome doesn’t yet have mobile-console functionality.

不幸的是,谷歌浏览器还没有移动控制台功能。

After a little bit of research, I was able to find a pretty useful solution in Safari, a web browser I haven’t used in years. It can achieve virtually the same thing that Google Chrome Console can, with no downloads or any extraneous work — aside from changing some settings on your iPhone and Mac. Here’s how you

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值