react-native-device-info: can not compile android with RN0.59 and rn-device info 3.1.1

Bug

The app with rn0.59 is not compileable for android

/****/node_modules/react-native-device-info/android/src/main/java/com/learnium/RNDeviceInfo/RNDeviceModule.java:34: error: cannot find symbol
import androidx.annotation.Nullable;
                          ^
  symbol:   class Nullable
  location: package androidx.annotation
/****node_modules/react-native-device-info/android/src/main/java/com/learnium/RNDeviceInfo/RNDeviceModule.java:916: error: cannot find symbol
                         @Nullable Object data) {
                          ^
  symbol:   class Nullable
  location: class RNDeviceModule
Note: /****/node_modules/react-native-device-info/android/src/main/java/com/learnium/RNDeviceInfo/RNDeviceModule.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
2 errors
3 warnings

Environment info

Describe what you expected to happen:

Reproducible sample code

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Reactions: 2
  • Comments: 20

Commits related to this issue

Most upvoted comments

🤦‍♂ apologies. thanks!

I’ve just got the RN59 example script working again if you want to clone it and see how exact steps showing how to get current release (4.0.1-beta.3 at time I write this) working with RN59

@mikehardy ok fair point. thanks a lot!

Read the readme.