You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
老哥, 我按照你的这样, 现在点击会跳到404界面, 控制台没有任何报错, 我打印了路由对象, 发现组件的component里面提示 arguments: [异常: TypeError: 'caller', 'callee', and 'arguments' properties may not be accessed on strict mode functions or the arguments objects for calls to them at Function.o (<anonymous>:1:83)]
老哥,我现在会按照你这样的点击打印到404界面,没有问题的报告错误,我的目标对象,发现组件的里面提示 arguments: [异常: TypeError: 'caller', 'callee', and 'arguments' properties may not be accessed on strict mode functions or the arguments objects for calls to them at Function.o (<anonymous>:1:83)]
Activity
PanJiaChen commentedon Aug 18, 2017
现在不管是路由的权限,还是用户的角色暂时都是本地写死的,所以增加权限修改页体验也不很好,我思考一下怎么展现好一点
tong3jie commentedon Aug 29, 2017
谢谢,期待中。
个人建议能否在demo中增加一个Mock接口,然后通过修改store下的permission.js动态从mock中获取的当前token对应的权限,然后在前端页中通过树形结构来动态加载并编辑的它们。
tong3jie commentedon Aug 29, 2017
看看翻看了issue的内容,看看有好几个跟我类似的需求,哈哈。请潘神考虑一下。
Hanjijiang commentedon Sep 21, 2017
同求,觉得权限后端获取到比较好
daiing commentedon Oct 9, 2017
同求,权限从后端获取权限列表
jianliulin commentedon Oct 28, 2017
同求,觉得权限后端获取到比较好+1
Danbaoshan commentedon Nov 16, 2017
同求,觉得权限后端获取到比较好+1
sunflower-tc commentedon Dec 1, 2017
同求,觉得权限后端获取到比较好+1
chensource commentedon Jan 4, 2018
同求~
20 remaining items
PanJiaChen commentedon Mar 15, 2019
#1605
已添加
在线demo
之后会添加服务端返回demo
fya0122 commentedon Jun 6, 2019
@ycg000344 老兄,你这个貌似只是一级跟二级菜单可以用吧?好像到了三级里面,children就出现不了!
fanbao1 commentedon Oct 9, 2019
@ycg000344 感谢!解决了~第四步不能省略吗?
// component: isParent ? Layout : () => import(item.component)
这种写法感觉更灵活,但是报找不到模块,求解决办法
zy784940112 commentedon Dec 17, 2019
怎么解决的
4550155 commentedon Feb 19, 2020
我也遇到同样的问题 请问解决了么?
yzbas123 commentedon May 19, 2020
component属性先存一个字符串,前端这边拿到进行解析,根据这个component生成一个路径,然后使用正常使用imoprt传入该生成的路径,我现在就这样做的
yanglin1994 commentedon May 26, 2020
为什么一直是空白,并且地址还不对,是哪里出现问题了?
yzbas123 commentedon May 26, 2020
@yanglin1994
我建议你用作者提到过的那种键值对形式管理import导入和你的component字段的字符串的关系,就是说那边component存一个字符串标识一下就行了,然后前端这边还要一个对象用来管理,component字符串对应导入哪个组件
yzbas123 commentedon May 26, 2020
@yanglin1994

类似这样的东西
fanbao1 commentedon Jun 20, 2020
store->modules->permission.js
pylist commentedon Apr 21, 2021
老哥, 我按照你的这样, 现在点击会跳到404界面, 控制台没有任何报错, 我打印了路由对象, 发现组件的component里面提示

arguments: [异常: TypeError: 'caller', 'callee', and 'arguments' properties may not be accessed on strict mode functions or the arguments objects for calls to them at Function.o (<anonymous>:1:83)]
huan0118 commentedon May 19, 2021
https://github.com/huan0118/p_admin
动态路由尝试
LuffyQAQ commentedon Sep 29, 2022
兄弟解决这个问题没,刚碰到这个问题