提交 c99b4020 编写于 作者: fxy060608's avatar fxy060608

fix(v3): remove circular dependencies

上级 05c91f3c
......@@ -2,13 +2,9 @@ import {
invoke
} from 'uni-core/service/bridge'
import {
onMethod
} from 'uni-core/service/platform'
const callbacks = []
onMethod('uniMPNativeEvent', function (res) {
// 不使用uni-core/service/platform中的onMethod,避免循环引用
UniServiceJSBridge.on('api.uniMPNativeEvent', function (res) {
callbacks.forEach(callbackId => {
invoke(callbackId, res.event, res.data)
})
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册