ant-design / ant-design-mobile-rn

Ant Design for React Native
https://rn.mobile.ant.design/
MIT License
3.04k stars 612 forks source link

[Bug] 使用 @ant-design/react-native 5.2.1 Form 组件报错 #1367

Open laoona opened 1 month ago

laoona commented 1 month ago

💬 前提强调

🙋 描述详情/重现步骤

简单代码:

import { View } from 'react-native';
import { Form } from '@ant-design/react-native';

export default function FormPage () {
  return <View>
    <Form />
  </View>;
}

只要引用了 Form 组件,就报下面的错误

image

🔴 版本

5.2.1

💻 运行环境

iOS

⚫️ npx react-native info输出信息

warn Package @ant-design/icons-react-native contains invalid configuration: "dependency.assets" is not allowed. Please verify it's properly linked using "npx react-native config" command and contact the package maintainers about this. info Fetching system and libraries information... System: OS: macOS 14.5 CPU: (10) arm64 Apple M1 Max Memory: 173.64 MB / 32.00 GB Shell: version: "5.9" path: /bin/zsh Binaries: Node: version: 18.16.0 path: ~/.nvm/versions/node/v18.16.0/bin/node Yarn: version: 3.6.4 path: ~/Library/pnpm/yarn npm: version: 9.5.1 path: ~/.nvm/versions/node/v18.16.0/bin/npm Watchman: version: 2023.12.04.00 path: /opt/homebrew/bin/watchman Managers: CocoaPods: version: 1.14.3 path: /Users/laoona/.rvm/gems/ruby-2.7.5/bin/pod SDKs: iOS SDK: Platforms:

补充说明

使用的 react-native 版本 0.74.3

1uokun commented 1 month ago

安装react-native-gesture-handler

https://github.com/ant-design/ant-design-mobile-rn/blob/master/README.zh-CN.md#%E5%AE%89%E8%A3%85peer%E4%BE%9D%E8%B5%96

laoona commented 1 month ago

安装react-native-gesture-handler

https://github.com/ant-design/ant-design-mobile-rn/blob/master/README.zh-CN.md#%E5%AE%89%E8%A3%85peer%E4%BE%9D%E8%B5%96

多谢,可以了。不过还报一个错误:

image
1uokun commented 1 month ago

是的,是一个warn,下个版本会修复发自我的 iPhone在 2024年8月8日,18:01,shilei @.***> 写道:

安装react-native-gesture-handler https://github.com/ant-design/ant-design-mobile-rn/blob/master/README.zh-CN.md#%E5%AE%89%E8%A3%85peer%E4%BE%9D%E8%B5%96

多谢,可以了。不过还报一个错误: image.png (view on web)

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you commented.Message ID: @.***>

laoona commented 1 month ago

跪谢大佬!!!