gpt4 book ai didi

react-native - React Native 中的 clipsToBounds

转载 作者:行者123 更新时间:2023-12-04 04:25:15 27 4
gpt4 key购买 nike

什么是 clipsToBounds = true 的替代品在 React Native 中?我有超出父 View 范围的 subview 。在使用 swift 的 iOS 中,我会用 clipsToBounds = true 解决它

最佳答案

您必须使用 style您的 View 和设置的属性 overflowhidden .像这样的东西:

<View style={{ overflow: ‘hidden’ }}>
{/* These views won’t be presented out of the view */}
</View>

关于react-native - React Native 中的 clipsToBounds,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/55282415/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com