React native 未找到模块:无法解析“./src/refreshableScrollView”
在我的应用程序中安装ant mobile后,我尝试在我的应用程序中使用卡组件,但当我在web或expo手机上启动应用程序时,我总是收到相同的错误。错误的完整日志为:未找到模块:React native 未找到模块:无法解析“./src/refreshableScrollView”,react-native,antd-mobile,React Native,Antd Mobile,在我的应用程序中安装ant mobile后,我尝试在我的应用程序中使用卡组件,但当我在web或expo手机上启动应用程序时,我总是收到相同的错误。错误的完整日志为:未找到模块: Can't resolve './src/refreshableScrollView' in 'C:\Users\User\Desktop\AwesomeProject\node_modules\@bang88\react-native-ultimate-listview 如果需要idk,但我发布的每一条信息,有人知道
Can't resolve './src/refreshableScrollView' in 'C:\Users\User\Desktop\AwesomeProject\node_modules\@bang88\react-native-ultimate-listview
如果需要idk,但我发布的每一条信息,有人知道如何解决吗?我最近也遇到了同样的问题,并且已经解决了这个问题 首先,您需要使用expo而不是npm安装ant mobile: expo install@ant design/react native 同时安装babel插件导入: expo安装babel插件导入 然后修改babel.config.js文件,如下所示:
module.exports = function(api) {
api.cache(true);
return {
presets: ['babel-preset-expo'],
plugins: [
['import', {libraryName: '@ant-design/react-native'}],
],
};
};
我最近也遇到了同样的问题,并且已经解决了这个问题 首先,您需要使用expo而不是npm安装ant mobile: expo install@ant design/react native 同时安装babel插件导入: expo安装babel插件导入 然后修改babel.config.js文件,如下所示:
module.exports = function(api) {
api.cache(true);
return {
presets: ['babel-preset-expo'],
plugins: [
['import', {libraryName: '@ant-design/react-native'}],
],
};
};