Console.log not displaying on iPad Pro Safari 16.4 when using dev tools on my mac
Asked Answered
D

4

11

I've tried 3 different websites to make sure the console is logging out as well as on my laptop and a different iPad. On the IPad Pro with the latest safari version - no console logging. Anyone experience this or know how to fix it?

Dieldrin answered 28/3, 2023 at 3:19 Comment(1)
I have the same issue. I have setup safari on ios to support remote debugging, and turned on developer features on safari on my laptop, but I see none of the console logs that I know are being firedMuriate
H
4

You need to download safari 16.4 on your mac from there : Apple Website

Then using that version of safari from your mac, you can connect to your pwa using 16.4 on iOS and have the console log working properly.

Hildahildagard answered 13/4, 2023 at 12:50 Comment(2)
updating safari fixed the issue for me on Monterey and iOS 17. none of the console messages were making it through - and now they do! thank you!!Resupinate
Thanks for this. It saved me having to update my whole operating system and likely break something else. It's a nuisance that Apple allows me to update an old iphone then causes it to break features with a newer device.There
H
4

Update macOS to Ventura and Safari will be 16.4

Hardening answered 19/4, 2023 at 4:15 Comment(1)
Can confirm that after updating macOS and thus Safari I now see console.logs from iPhone via USB debugging.Helvellyn
D
2

Apparently this is by design now with iOS 16.4. You need to actually mark the webview as inspectable even while running in debug mode from Xcode. See blog post at https://webkit.org/blog/13936/enabling-the-inspection-of-web-content-in-apps/

If you're on Capacitor, there are more details and a temporary workaround here: https://github.com/ionic-team/capacitor/issues/6441

Dominickdominie answered 11/4, 2023 at 3:32 Comment(2)
How does this apply to PWAs. There is no swift or xcode involved so no way to use any of the code in that article?Muriate
I'm building a website using next.js, hsoting it vercel. Connecting my iPad to my laptop via a USB-C cable and using the development mode in safari to inspect the web page if that helps.Dieldrin
K
0
  1. Open Safari on your Mac
  2. open the developer setting in Safari
  3. choose your device and enable the option "Automatically Show Web Inspector for JSContexts" (see image)
  4. enter image description here
Kenwood answered 6/9, 2024 at 20:4 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.