Web Inspector

RSS for tag

Discuss Web Inspector, which gives you quick and easy access to the richest set of development tools ever included in a web browser.

Posts under Web Inspector tag

9 Posts

Post

Replies

Boosts

Views

Activity

iOS Safari Web Extension MV3 - How to debug service workers?
I'm developing a web extension for Safari on iOS using MV3. The extension is working fine in Chrome, but in Safari I experience some seemingly random issues. I would like to debug it, but here is my problem. I have my iPhone connected via cable to Mac, and it works fine with XCode, so I assume this part is OK. I open Safari or Safari Tech Preview (doesn't matter) on my Mac, developers options are enabled, and in the Develop menu, under my iPhone section, there are things I can debug. There is an entry "[Ext name] - Extension Service Worker" but when I click it, it's empty. Web inspector pops up, but there are no network requests, no logs, nothing. I know the extension is working, because I can stream log to my HTTP server, but I don't see them here at all. I can use console to trigger commands like chrome.storage.local.get(null, console.log) and it shows my local store, so why I don't see any logs? Also, the background script is not visible in the Sources tab, just one weird request: navigator.serviceWorker.register('safari-web-extension://E3449EA7-EC25-4696-8E6C-[ID HERE]/background.js'); </script> Any ideas what went wrong? The entire team of 4 people has the same issue and we can't move forward because of that. Also, the Develop => Service workers or any other menu section doesn't show my service worker. Logs for websites running on my phone are visible and in general web inspector for them works fine.
1
2
936
1w
Why does my website header look different in Safari on macOS compared to Windows browsers?
Hi Developers, I am working on a small project and I noticed that my website header looks different in Safari on macOS compared to Windows browsers like Chrome and Edge. In Safari, the header text and spacing look slightly shifted (screenshot attached). On Windows browsers, everything looks perfectly aligned. Here is my live project for reference: https://gratuitycalculatorae.com/ Screenshot from Safari (macOS): Is this related to Safari-specific CSS rendering? Should I use -webkit- specific fixes or is there a better cross-browser solution? Any guidance or best practices would be really helpful. Thanks
1
0
73
1w
Worker load was blocked by Cross-Origin-Embedder-Policy
Hello, I am developing a website which starts a web worker using the js code: const zarrWorker = new Worker('./zarr_file.js', { type: 'module' });. The script 'zarr_file.js' is served from the same origin with Cross-Origin-Embedder-Policy: require-corp and Cross-Origin-Opener-Policy: same-origin and it is importing external modules through the import statement (e.g. import * as zarr from "https://cdn.jsdelivr.net/npm/zarrita/+esm";). All the external modules are blocked by Safari with the error Worker load was blocked by Cross-Origin-Embedder-Policy, although I can see (by running curl on them) that they correctly set cross-origin-resource-policy: cross-origin`. The same website works fine in Chrome and Firefox. Is it a bug or is Safari implementing stricter policies? In the latter case what would be the solution?
0
0
91
Aug ’25
httpd.conf syntax to include Homebrew extensions for php and mySQL
I have "http://localhost:8080" showing the index page I've created but php is not handled though an extension is running. Haven't even tried mySQL yet but since there is no reference to it in https.conf the same problem will exist. Homebrew extension running also. https.conf: #PHP was deprecated in macOS 11 and removed from macOS 12 #LoadModule php7_module libexec/apache2/libphp7.so There are no php.so files on my machine and again no mention of mysql What should I enter in http.conf to activate these functionalities? Thanks. PS could you reference a tutorial on using Safari and Web inspector
1
0
85
Jun ’25
XMLHttpRequest cannot load https://demo2.artios.cz/app37g/v105/php/endpoint.php due to access control checks
Hi, we are experiencing a strange issue with our Web App. Our web app runs entirely on the same domain , and we are making several AJAX requests to the same server. The Error occurs only on Iphones, the app works completely fine on androids and computers. Most of the requests work fine, but suddenly, one specific request always fails with the following error: XMLHttpRequest cannot load https://demo2.artios.cz/app37g/v105/php/endpoint.php due to access control checks What we have checked so far: ✅ CORS headers seem correct. Also we operate entirely on the same domain, client and server. ✅ The same request works fine in computer and android devices. ✅ The issue occurs only on iPhone (tested on Chrome and Safari). ✅ Some requests to the same endpoint pass, but suddenly, this specific request always fails. ✅ There is no OPTIONS preflight request logged in the network tab, but we use only simple requests. ✅ We are making a POST request with multipart/form-data. What is Your advice, or where I can find more info about this error? We do not think the CORS is the problem. We have tried to inspect with WebInspector but with no relevant answers. Thank You very much!
0
1
512
Feb ’25
PWA Web Push not arriving on iOS 18.0 - solved
Update: turns out the testphone with iOS 18 was set to 'Do not disturb'. Case closed. Hi all, I created a progressive web app. I is hosted on an actual live domain, served over https. When installed on an iPhone homescreen on iOS 17.7.2, sending web push notifications works fine: the response from the push service endpoint has a status code of 201, indicating all is good. In the service worker of the PWA, an eventlistener for the 'push' event is trigggered and displays an OS notification. On iOS18.0 however, even though the response from the push service endpoint has a status code of 201, there is no notification showing. Even though permission has been granted, and registration.pushManager.subscribe() is successful. When working locally, I've setup my server to run on localhost in https mode as well by following this excellent Technical Note to setup my own Certificate Authority, have it be trusted by my iOS test devices and have the CA issue a certificate so TLS can be set up. On this locally running https server, web push notifications do arrive for iOS 17.7.2, but also not for iOS18.0. I'm not sure how to start debugging this, as I can't seem to get the webinspector to show for the service worker most times, and when I can, there is no console.log() output visible. This still stands: So really, I'm looking for a (reliable) way to be able to debug this issues in safari, or find some documentation on what changed for Safari on iOS 18 that requires changes. Any help or thoughts on this matter?
1
0
842
Dec ’24