When an iOS device is connected via Remote Debugging, your machine will treat it as if it is connected locally via USB.
This allows Safari to see the device as locally connected which is why it then enables you to debug your mobile site.
When debugging mobile sites using Safari on Mac, Safari must be closed before the Remote Debugging session is initiated.
1. You should use Chrome to open the device and initiate the Remote Debugging session.
2. When starting the session from command line, i.e., ./rdb start-remote-debug --url <> --access-key <> --serial-number <>
3. And only then open Safari on your Mac machine - and the developer tools.
4. Troubleshooting - in some cases - inspecting safari might have some issues, you can add the following optional flag "--debug-safari" to the command line, i.e. ./rdb start-remote-debug --url <> --access-key <> --serial-number <> --debug-safari
In case session was started, but you cannot inspect websites on the debugged device, you can follow these steps:
- Locate the installation dir, and locate *.vmoptions file inside it
- Add "-Ddebug.safari=true" to vmoptions file, followed by a line break.
- Then restart the remote debugging service.