【发布时间】:2020-04-17 20:40:29
【问题描述】:
我正在使用来自this pod 的左侧菜单使用情节提要。 sidemenu 在 Swift 4.2 版本的 pod 中运行良好。但是我在这里更新了 Swift 5 中的 pod 我没有在属性检查器中获取此菜单以提供左侧菜单,
在 Swift 5 pod 'SideMenu', '~> 6.0' 我从下方获取完整菜单,但没有获取左侧菜单。
这就是我尝试在 appDelegate 中添加此代码的原因:
let leftMenuNavigationController = SideMenuNavigationController(rootViewController: YourViewController)
SideMenuManager.default.leftMenuNavigationController = leftMenuNavigationController
但是这里我应该在YourViewController 地方写什么
在控制台中我得到如下:
无法在 (UINavigationController) 上设置 (leftSide) 用户定义的检查属性:[ setValue:forUndefinedKey:]:此类不符合键 leftSide 的键值编码。
这是一个小型演示项目,您可以在此处找到 pod 安装和错误 github project
我需要像这样的侧边菜单。我曾经在 Swift 4 pod 中获得这样的菜单
如何在更新版本中添加左侧菜单?
【问题讨论】:
-
更新了答案
标签: ios swift swift5 side-menu