このライブラリを使用して、iOS アプリのサイドメニューを実装しようとしてい ますhttps://github.com/jonkykong/SideMenu
let menuRightNavigationController = UISideMenuNavigationController(rootViewController: SideMenuViewController())
SideMenuManager.default.menuRightNavigationController = menuRightNavigationController
SideMenuManager.default.menuFadeStatusBar = false
SideMenuManager.default.menuAddPanGestureToPresent(toView: self.navigationController!.navigationBar)
SideMenuManager.default.menuAddScreenEdgePanGesturesToPresent(toView: self.navigationController!.view)
しかし、アプリケーションは上記のコードの最後の 2 行でクラッシュし、以下のコードはボタン アクションで記述されています。
@objc func menuButtonAction(sender: UIButton!) {
present(SideMenuManager.default.menuRightNavigationController!, animated: true, completion: nil)
}
サイドメニューを表示できるように、クラッシュの処理を手伝ってください。ありがとう!