首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >错误:未知的命名模块"react-native-webrtc“

错误:未知的命名模块"react-native-webrtc“
EN

Stack Overflow用户
提问于 2021-05-09 07:47:32
回答 1查看 307关注 0票数 0

在发布之前,我在android上的react原生应用程序中看到了这个错误。我还没有在iOS上测试过

这是我的地铁复印件

代码语言:javascript
复制
 BUNDLE  ./index.js

 WARN  AsyncStorage has been extracted from react-native core and will be removed in a future release. It can now be installed and imported from '@react-native-async-storage/async-storage' instead of 'react-native'. See https://github.com/react-native-async-storage/async-storage
 ERROR  Error: Unknown named module: "react-native-webrtc"
 ERROR  Invariant Violation: Module AppRegistry is not a registered callable module (calling runApplication). A frequent cause of the error is that the application entry file path is incorrect.
      This can also happen when the JS bundle is corrupt or there is an early initialization error when loading React Native.
 ERROR  Invariant Violation: Module AppRegistry is not a registered callable module (calling runApplication). A frequent cause of the error is that the application entry file path is incorrect.
      This can also happen when the JS bundle is corrupt or there is an early initialization error when loading React Native.

我的index.js

代码语言:javascript
复制
/**
 * @format
 */

import {AppRegistry} from 'react-native';
import MainProject from './App';
import {name as appName} from './app.json';
import {Provider} from 'react-redux';
import {Provider as PaperProvider} from 'react-native-paper'
import store from './videocall/store'
import 'react-native-gesture-handler'
const AppRedux = () => (
    <Provider {...{store}}>
        <PaperProvider>
            <MainProject />
        </PaperProvider>
    </Provider>
)
AppRegistry.registerComponent(appName, () => AppRedux);

我已经试过答案here了,不起作用。

这是package.json

代码语言:javascript
复制
"react": "17.0.1",
"react-native": "0.64.0",
"react-native-peerjs": "^1.0.4",
"react-native-webrtc": "1.89.1
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2021-05-10 05:04:55

意识到它只出现在1.89.1

降级到1.84.1对我来说很有效

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/67453148

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档