DylanVann / react-native-fast-image

🚩 FastImage, performant React Native image component.
MIT License
8.09k stars 1.47k forks source link

Declaration of 'RCTDirectEventBlock' must be imported from module 'React.RCTView' #968

Open obie3 opened 1 year ago

obie3 commented 1 year ago

To Reproduce

  1. Go to 'ios directory of the project on xcode'
  2. Try to build the application
  3. Build fails with error message below
  4. See error message below /Users/projectDir/node_modules/react-native-fast-image/ios/FastImage/FFFastImageView.h:13:29 Declaration of 'RCTDirectEventBlock' must be imported from module 'React.RCTView' before it is required

Expected behavior

The app was supposed to build successfully without any error

Dependency versions

GoktuqCan commented 6 months ago

I had the same issue with another library.

Solution: Cleaning Derived Data folder worked for me : Go to Xcode -> Settings -> Locations -> Derived Data -> Click on the right arrow icon Delete the Derived data folder and run again.

tonyebrown commented 5 months ago

@GoktuqCan this solved my issue, plus a few other similar ones. Thanks!