capacitor.js 6: backswipe on ios

i just implemented code from george hoeller's article, however it didn't work with capacitor 6 anymore. so i linked it using MyViewController , as the docs say.

code

{`// ios/App/App/plugins/BackswipePlugin.swift

import Foundation
import Capacitor

@objc(BackswipePlugin)
public class BackswipePlugin: CAPPlugin {
    
    override public func load() {
        bridge?.webView?.allowsBackForwardNavigationGestures = true;
    }
}`}
	
{`// ios/App/App/plugins/Backswipe.m

#import 
#import 

CAP_PLUGIN(BackswipePlugin, "BackswipePlugin",)`}
	
{`// ios/App/App/MyViewController.swift

import UIKit
import Capacitor

class MyViewController: CAPBridgeViewController {

    override func viewDidLoad() {
        super.viewDidLoad()
    }
    
    override open func capacitorDidLoad() {
        bridge?.registerPluginInstance(BackswipePlugin())
    }
}`}