jd-solanki / anu

Anu - DX focused utility based vue component library built on top of UnoCSS & VueUse ⚡️🔥

Home Page:https://anu-vue.netlify.app/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

feat:Role component

jingyuexing opened this issue · comments

<!-- only validate is true can be view this page -->
<Role validate="vadalidatePermissions">
    <router-view></router-view>
</Role>
<!-- only admin can be view -->
<Role type="admin">
    <router-view></router-view>
</Role>

<!-- only pro can be view -->
<Role type="pro">
    <router-view></router-view>
</Role>
<!-- only devloper can be view -->
<Role type="dev"> 
    <router-view></router-view>
</Role>

We don't have any plans for introducing access control related component any time soon. I recommend you use CASL. I also use this at my company in our premium template.