Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I'm fairly confident I did that. Either way, the process is very unclear - what actually notifies Safari that an extension is available and whether it's updated?

With most browsers it's clear, you open a specific file with the browser, the browser loads it and that's it. To update, you open the updated version of the file.

With these apps it doesn't even seem like the app itself is doing any work - there's no code in there to for example connect to an internal socket or do some IPC to notify the browser and supply it with extension files - instead it seems to be handled out-of-band by "magic".



> what actually notifies Safari that an extension is available and whether it's updated?

Since extensions are made available via app extensions, it is:

- installation of an app from the app store

- first run of an app which is not from the app store

This is actually the big reason why they require you to use apps - all system customizations (device drivers, web extensions, photo plugins, fonts, etc) are supported with an application life cycle, and support appstore-style review and updates.

I haven't done enough development of safari app extensions in particular to fully understand how _live_ updates work. I typically just enabled the extension with Safari Tech Preview as the only extension, loaded on a test page, and would restart. There may well be logic now to do a page refresh when an enabled extension is updated, however.

> With these apps it doesn't even seem like the app itself is doing any work - there's no code in there to for example connect to an internal socket or do some IPC to notify the browser and supply it with extension files

The app extension has a global JS file loaded, and the safari.extension object allows one to send IPC to the corresponding native Mac app. This is (for example) how 1Password and other password managers integrate with the native password store.

The native app is a pretty good place to put all the configuration options for your extension, which may eliminate the need to surface browser-bar buttons and the like.

(FWIW: my Safari extension was a prototype that was abandoned because Safari didn't surface enough HTTP request/response access in their old API. I haven't checked yet if their Web Extension API surface includes what I needed.)


> didn't surface enough HTTP request/response access in their old API. I haven't checked yet if their Web Extension API surface includes what I needed

Nope, which is why uBlock Origin is still not possible.




Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: