Forcing iOS Safari to share as Web Archive

Safari in iOS 13 has gained the ability to share web pages as Web Archives. By default, share options are set to Automatic however, which explains that it will "pick the most suitable format for each app or action". With share or action extensions, it seems that always results in Safari just sharing the URL however (the item provider only supports type `public.url`). I'm wondering if there's a way for extensions to indicate which format they prefer to receive, without asking the user to manually select the appropriate format each time they share a page.


I've tried setting `NSExtensionActivationRule` to a predicate that only accepts `com.apple.webarchive`. This results in the extension only showing up once the user manually changes the share option from Automatic to Web Archive, which is not really what I was hoping it would do.


Has anyone found a solution for this? Am I missing something?


(This isn't really about Safari App Extensions, but I wasn't sure where else to post this.)

Replies

Did you receive an answer? I had saved a few pages as web archives on my iPhone, but when I airdropped them to my Mac it says it cannot open them because they are from an unknown developer. I'm not sure what to do about that.