react-native-shadow icon indicating copy to clipboard operation
react-native-shadow copied to clipboard

TypeError: Invalid attempt to spread non-iterable instance.In order to be iterable, non-array objects must have a [Symbol.iterator]() method.

Open geekayush1812 opened this issue 4 years ago • 2 comments

import React from 'react'; import {View} from 'react-native'; import {BoxShadow, BorderShadow} from 'react-native-shadow';

function Neumorphic() { const shadowOpt = { width: 100, height: 100, color: '#000', border: 2, radius: 10, opacity: 0.18, x: 2, y: 2, }; const shadowOpt1 = { width: 100, height: 100, color: '#fff', border: 2, radius: 10, opacity: 0.18, x: -2, y: -2, }; const shadowOpt2 = { width: 100, color: '#fff', border: 2, opacity: 0.18, side: 'top', inset: true, }; return ( <View style={{ flex: 1, justifyContent: 'center', alignItems: 'center', position: 'relative', backgroundColor: '#eee', }}> {/* <BoxShadow setting={shadowOpt1}> <BoxShadow setting={shadowOpt}> <View style={{ width: 100, height: 100, backgroundColor: '#fefefe', borderRadius: 10, }} /> </BoxShadow> </BoxShadow> */} <BorderShadow setting={{side: 'bottom'}}> <View style={{ width: 100, height: 100, backgroundColor: '#fefefe', borderRadius: 10, }} /> </BorderShadow> </View> ); }

export default Neumorphic;

geekayush1812 avatar Apr 27 '20 11:04 geekayush1812

Having the same issue, any help?

MichaelKim39 avatar Sep 18 '20 08:09 MichaelKim39

https://github.com/879479119/react-native-shadow/issues/31#issuecomment-636629468 works for me

brunosantanarj avatar Dec 01 '20 16:12 brunosantanarj