会员
周边
捐助
新闻
博问
闪存
赞助商
所有博客
当前博客
我的博客
我的园子
账号设置
简洁模式
...
退出登录
注册
登录
小十六哇
博客园
首页
新随笔
联系
管理
订阅
2021年8月12日
vue兄弟间传值 $emit触发 $on监听 $off 关闭传值
摘要: 定义一个公共的bus.js import Vue from 'vue'; export const Bus = new Vue(); 在页面引A import {Bus} from '../../bus.js'; Bus.$emit('one') //触发 在页面B import {Bus} fro
阅读全文
posted @ 2021-08-12 09:18 小十六哇
阅读(187)
评论(0)
推荐(0)
编辑
公告