softgenicsShubham / react-native-device-brightness-new

Device brightness package for Android and Ios
https://www.npmjs.com/package/react-native-device-brightness-new
MIT License
2 stars 1 forks source link

Missing header references with RN 0.76.x #1

Open ppolus-miquido opened 2 weeks ago

ppolus-miquido commented 2 weeks ago

My build fails with RN 0.76.

node_modules/react-native-device-brightness-new/ios/generated/build/generated/ios/react/renderer/components/RNDeviceBrightnessNewSpec/States.cpp:10:10 'react/renderer/components/RNDeviceBrightnessNewSpec/States.h' file not found

thibaultcapelli commented 1 week ago

Hello @ppolus-miquido

Did you find a solution for this ?

thibaultcapelli commented 1 week ago

I finally found a fix comparing with a fresh initialized library

The issue is that "includesGeneratedCode": true looks needed in the codegenConfig for new RN versions ?

So I had to:

You can now use the result in ios/generated as a patch

I will create a PR for this to create a new version

ppolus-miquido commented 6 days ago

My only conclusion is that the library files are not being copied to the ios/build/generated directory. As a quick fix, I've been manually copying those files. However, I'm still unsure how to get the pod install command to handle this automatically. FIngers crossed your PR will fix it.