Skip to content

Commit bcf0869

Browse files
committed
feat(wx-react-native): 添加DeviceEventEmitter not support 说明
1 parent f7dbbf7 commit bcf0869

File tree

2 files changed

+13
-3
lines changed

2 files changed

+13
-3
lines changed

packages/wx-react-native/miniprogram_dist/index.js

+12-2
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,14 @@ const NativeAppEventEmitter = {
7474
}
7575
},
7676
}
77+
const DeviceEventEmitter = {
78+
addListener: () => {
79+
console.warn('use @areslabs/wx-eventemitter instead')
80+
return () => {
81+
console.warn('use @areslabs/wx-eventemitter instead')
82+
}
83+
},
84+
}
7785

7886
export {
7987
WXButton,
@@ -122,7 +130,8 @@ export {
122130
cancelAnimationFrame,
123131
unstable_batchedUpdates,
124132
AppState,
125-
NativeAppEventEmitter
133+
NativeAppEventEmitter,
134+
DeviceEventEmitter
126135
}
127136

128137
export default {
@@ -173,5 +182,6 @@ export default {
173182
cancelAnimationFrame,
174183
unstable_batchedUpdates,
175184
AppState,
176-
NativeAppEventEmitter
185+
NativeAppEventEmitter,
186+
DeviceEventEmitter
177187
}

packages/wx-react-native/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@areslabs/wx-react-native",
3-
"version": "1.0.22",
3+
"version": "1.0.23",
44
"description": "微信版本的React Native",
55
"main": "index.js",
66
"scripts": {

0 commit comments

Comments
 (0)