mirror of
https://github.com/zhigang1992/react-native-shadow-view.git
synced 2026-04-28 12:25:15 +08:00
b1f438caf07b54ac039ddf1822e46a98fc339474
react-native-shadow-view
React Native's View Component with Shadows Both on Android and iOS, inspired by react-native-shadow
Install
Install react-native-svg first
$ npm install react-native-shadow-view --save
Usage
import ShadowView from 'react-native-shadow-view'
const Example = (props) => (
<ShadowView style={{
width: 348,
height: 470,
backgroundColor: 'white',
borderRadius: 10,
justifyContent: 'center',
alignItems: 'center',
shadowColor: '#000',
shadowOffset: {
width: 0, height: 2,
},
shadowOpacity: 0.3,
shadowRadius: 4
}}>
<Text>{data}</Text>
</ShadowView>
)
Known Issues
- The
widthandheightof theViewstyle must be specified.
Languages
TypeScript
52.2%
JavaScript
47.8%