Home > OS >  Is React Native Out of Date?
Is React Native Out of Date?

Time:01-21

I want to use to use React Native for a project at work, but based on their guide for setting up the development environment, it seems like it's out of date.

Reading the guide for setting up React Native at https://reactnative.dev/docs/environment-setup, I read:

...We recommend JDK11. You may encounter problems using higher JDK versions.

The Java SE Development Kit (JDK) is at version 19 now, so this was my first red flag. Additionally, it reads:

Building a React Native app with native code, however, requires the Android 12 (S) SDK in particular.

When choosing the option for that SDK when creating a new project in Android Studio, it tells me, "Your app will run on approximately 24.1% of devices."

I can't move forward if this won't work on most devices, however I read that React Native is still popular today. I'm not sure that's possible given that 24.1%. Can anyone help clear this up? Are there caveats for that statistic that I read?

For context, this is a simple smartphone app for submitting forms.

CodePudding user response:

Yes, React Native works with modern Android and iOS phones, and is still under active development.

Yes, JDK 11 is recommended in the docs, and is the version of the JDK you should develop React Native with.

When you create a new React Native project from the CLI, the compilation and target OS versions are not controlled by which JDK you have installed. They are set in your build.gradle:

  buildscript {
    ext {
        buildToolsVersion = "31.0.0"
        minSdkVersion = 23
        compileSdkVersion = 31
        targetSdkVersion = 31

That's all you need to worry about in terms of which devices you can support. It's not recommended to modify those versions, which depend on the version of React Native you start your project in. However, I've raised the target due to dependencies before, and nothing has exploded.

You can see some of the brands who use it to write their apps on RN's showcase on Github. Most of those apps include forms, so you should be covered there.

  • Related