tokkozhin/react-native-neomorph-shadows

Using "inner" or "useArt" crashing on IOs

DooaRashidAnsari opened this issue Β· 16 comments

I have added a neomorph component like this :
<Neomorph
darkShadowColor={Attrs.commonDarkShadowColor} // <- set this
lightShadowColor={Attrs.commonLightShadowColor}
inner={true}
useArt={true}
style={styles.background}
/>

IOs build is crashing on this line :

  • (void)setShadow:(ARTShadow)shadow
    {
    [self invalidate];
    _shadow = shadow;
    }

Above lines are located in ARTNode.m file

i got this problem to

This is the error
Your Component is accessing findNodeHandle inside its render(). render() should be a pure function of props and state. It should never access something that requires stale data from the previous render, such as refs. Move this logic to componentDidMount and componentDidUpdate instead

hi, im try to release a new version of my app. but got this error. how can i slove this ?

I my case i achieved same effect as inner using dark color in place of lightShadowColor and light color in place of darkShadowColor with swapShadows={true} and removed inner and useArt. Just a workaround. Something like this:

<Neomorph
darkShadowColor={Attrs.commonLightShadowColor}
lightShadowColor={Attrs.commonDarkShadowColor}
style={styles.background}
swapShadows={true}

/>

The issue is related to the @react-native-community/art module. There is a fix for this: react-native-art/art#70 but it is not released yet.

As a workaround install the latest code from the art repo:
npm i https://github.com/react-native-art/art.git

same issue~

The issue is related to the @react-native-community/art module. There is a fix for this: react-native-art/art#70 but it is not released yet.

As a workaround install the latest code from the art repo:
npm i https://github.com/react-native-art/art.git

This is also not working. If you are not using inner shadow and useArt option then you can avoid using that option and it will work for ios.

The issue is related to the @react-native-community/art module. There is a fix for this: react-native-art/art#70 but it is not released yet.
As a workaround install the latest code from the art repo:
npm i https://github.com/react-native-art/art.git

This is also not working. If you are not using inner shadow and useArt option then you can avoid using that option and it will work for ios.

works for me

hey guys, is this fixed yet? Or is there a hope that it's gonna be fixed soon?

Some news about a new version guys?
I tried install the latest code from art repo but I got Malformed calls from JS in the lib components

Honestly, this lib is unreliable. I am copying it down and maintaining it as part of the app

I couldn't get it working with yarn add https://github.com/react-native-art/art.git

so I used a patch file for this fix using patch-package

patch file: @react-native-community+art+1.2.0.patch.zip

I couldn't get it working with yarn add https://github.com/react-native-art/art.git

so I used a patch file for this fix using patch-package

patch file: @react-native-community+art+1.2.0.patch.zip

It worked for me after struggling a bit.
I would say after you have done patching ....please delete the app from Simulator or Device and reinstall it and then test.
just running yarn ios may not work

I couldn't get it working with yarn add https://github.com/react-native-art/art.git

so I used a patch file for this fix using patch-package

patch file: @react-native-community+art+1.2.0.patch.zip

Worked for me. Thank you very much!

I couldn't get it working with yarn add https://github.com/react-native-art/art.git

so I used a patch file for this fix using patch-package

patch file: @react-native-community+art+1.2.0.patch.zip

Works for me, thanks!