01 2021 档案

摘要:方式1 Props 父组件代码 <template> <!-- 父组件 --> <div class="parent"> <Child :num="count" @handle="changeValue" /> <button @click="add">父组件的按钮</button> </div> 阅读全文
posted @ 2021-01-11 20:43 祁腾飞 阅读(14529) 评论(0) 推荐(0) 编辑
摘要:首先在组件中导入 getCurrentInstance 1 import { 2 defineComponent, 3 reactive, 4 getCurrentInstance // 从此函数的返回值中获取到ctx属性调用$router.push() 5 } from 'vue' 然后在setu 阅读全文
posted @ 2021-01-10 20:26 祁腾飞 阅读(1370) 评论(1) 推荐(0) 编辑
摘要:main.ts代码 import { createApp } from 'vue' import App from './App.vue' import router from './router' import store from './store' // Element Plus import 阅读全文
posted @ 2021-01-10 13:10 祁腾飞 阅读(8655) 评论(3) 推荐(2) 编辑

点击右上角即可分享
微信分享提示