摘要: 先看下store部分目录结构 在看index.js中的结构 book.js中的数据 getters里面的数据 组件中的数据:在组件中引入mapGetters就是将vuex中的数据映射到组件的计算属性当中,映射到的数据能够直接使用 参考博客原址:https://blog.csdn.net/qq_407 阅读全文
posted @ 2020-04-15 20:57 star-meteor 阅读(2770) 评论(0) 推荐(0)
摘要: <template> <div class="dashboard-container"> <!-- 根据角色,切换组件 --> <component :is="currentRole" /> </div> </template> <script> import { mapGetters } from 阅读全文
posted @ 2020-04-15 20:27 star-meteor 阅读(389) 评论(0) 推荐(0)