ionic-team / ionic-team/capacitor
[Feature]: Overriding WebViewDelegationHandler
- Dominant language
- TypeScript
- Stars
- 16.7k
- Forks
- 1.3k
- Avg merge
- 3d 15h
- Merged PRs (30d)
- 10
Description
### Description
I can't seem to find a way to override the standard WebViewDelegationHandler
### Platforms
- [x] iOS
- [ ] Android
- [ ] Web
### Request or proposed solution
I was trying to find a way to use my own "WebViewDelegationHandler" and looking at this issue https://github.com/ionic-team/capacitor/issues/6605
In this PR https://github.com/ionic-team/capacitor/pull/6894 I see that someone correctly abstracted the instantiation of certain object (e.g. the new "func router()" that can be found [here](https://github.com/ionic-team/capacitor/blob/main/ios/Capacitor/Capacitor/CAPBridgeViewController.swift#L112-L114).
However, the instantiation of "WebViewDelegationHandler" is in a private function [here](https://github.com/ionic-team/capacitor/blob/main/ios/Capacitor/Capacitor/CAPBridgeViewController.swift#L56) basically making it extremely hard to subclass.
Would a PR to move this into an extensible function (like "Router") be welcome?
### Alternatives
_No response_
### Additional Information
_No response_
Contributor guide
Assessment
This issue has not been assessed yet.