Is there any way to generate a .webarchive from iOS? I know that WKWebView can render them without any issues (generated them on macOS for example), but it seems that there's no API to generate one from iOS itself.
It seems that not so long ago such feature became available on WebKit, but it's not yet available to the public API of WKWebView: https://github.com/WebKit/webkit/commit/7bc9562269dacab6b75833e3d00be3c4f616bfd4
Would Apple consider making such API public? I'm assuming that it's what's being used on the Reading List to save articles offline.
It seems that not so long ago such feature became available on WebKit, but it's not yet available to the public API of WKWebView: https://github.com/WebKit/webkit/commit/7bc9562269dacab6b75833e3d00be3c4f616bfd4
Would Apple consider making such API public? I'm assuming that it's what's being used on the Reading List to save articles offline.
createWebArchiveData is available in Beta 2, and it seems to do exactly what I needed. Kudos to the team! 👏
Link to the docs: https://developer.apple.com/documentation/webkit/wkwebview/3650491-createwebarchivedata
Link to the docs: https://developer.apple.com/documentation/webkit/wkwebview/3650491-createwebarchivedata