13

I'm trying to debug a web app that is added to home screen. I have enabled web inspector on safari. I am able to debug the app if I open in iOS safari but when I add the app to home screen and try to debug, it shows 'No Inspectable Applications'. Any help would be appreciated.

iOS version: 11.2

MacOS Safari version: 11.0.1

Gunner
  • 736
  • 11
  • 19
  • Try to update your iOS if you haven't done yet, then you will see in the pending updates the new safari version. See the [SO post](https://stackoverflow.com/questions/26014850/debugging-mobile-safari-in-ios-8-and-ios-9) for reference. Also, if you have enabled private browsing in `Settings > Safari`, it could also help if you turned it off as what [this answer in this SO post](https://stackoverflow.com/a/16999456) implies. – MαπμQμαπkγVπ.0 Dec 10 '17 at 11:26
  • @MαπμQμαπkγVπ.0 I tried all the settings mentioned in the links above but still no luck. I'll edit the question and add OS version. Hope that would narrow down a few things. – Gunner Dec 11 '17 at 05:13
  • @Gunner Hi, did you find a solution to your issue? I'm facing the same problem right now and it's driving me nuts. – Getter Jetter Sep 30 '19 at 12:48
  • 1
    @OlivierKrull Hi. Unfortunately no. I'm waiting for this same as you. In the mean time, debugging is a lot of trial and error. – Gunner Oct 01 '19 at 03:40
  • Same here. Now that adding to home screen is essential for web push notifications this is becoming ever more pressing @apple – Simon H Apr 05 '23 at 11:08

2 Answers2

1

You should put focus on the app first and then press:

Option+Command+i

So you do not open the inspector in advance in this case. This is not possible because you can consider it like opening a new browser tab where it makes no sense to inspect it from the inspector in another tab that is already open. Since the menu to open the inspector is missing when the PWA is opened as a desktop app, you need the keyboard shortcut to show it.

Jos
  • 419
  • 3
  • 12
  • 2
    Actually, the app is opened as a PWA on iPhone, which I'm trying to debug on mac. The problem is, when I open the app on iPhone safari, the dev tools show up, but when I add it to home screen on iPhone, then I'm getting 'No Inspectable Applications'. – Gunner Dec 14 '17 at 05:13
  • Maybe this helps: https://stackoverflow.com/questions/11262236/ios-remote-debugging/22047495#22047495 – Jos Dec 14 '17 at 14:03
1

Not sure if it's related, I had an issue where I couldn't get the inspector window to open for a cordova web app on iOS 11.2

I found that I had to go back to (ios) settings and toggle Safari Web Inspector off and on while looking at the (osx safari) developer menu to see it and then inspect it.

Daniel Swiegers
  • 4,631
  • 1
  • 8
  • 13
  • I tried this, but no luck. I'm not sure if this helps, but the app I'm trying to debug is not a cordova web app. Just a plain web app. Is there any setting other than web inspector I need to toggle for the PWA to show up under 'inspectable applications' in mac safari? – Gunner Dec 14 '17 at 05:16
  • Try updating safari if it's not the latest or try the safari [Technology Preview](https://developer.apple.com/safari/technology-preview/) – Daniel Swiegers Dec 15 '17 at 03:36
  • Sorry, I did not get time to install this and check. Will check and post if it works. – Gunner Dec 18 '17 at 06:45
  • I tried with safari Technology Preview. Still the same issue. It does not show up in develop menu under my iPhone. – Gunner Dec 18 '17 at 12:11