Why not start the application after installing the module on react native?

Hi all. Have installed the module react native device info to find out the id of your Android device. But when I run it gives an error. Ordered links using the react-native link react-native-device-info. After you unlink also does not start.

C:\apps\react\showdriver\android\app\src\main\java\com\showdriver\MainActivity.java:3: error: package com.facebook.react does not exist
import com.facebook.react.ReactActivity;
^
C:\apps\react\showdriver\android\app\src\main\java\com\showdriver\MainActivity.java:5: error: cannot find symbol
public class MainActivity extends ReactActivity {
^
 symbol: class ReactActivity
C:\apps\react\showdriver\android\app\src\main\java\com\showdriver\MainApplication.java:6: error: package com.facebook.react does not exist
import com.facebook.react.ReactApplication;
^
C:\apps\react\showdriver\android\app\src\main\java\com\showdriver\MainApplication.java:7: error: package com.facebook.react does not exist
import com.facebook.react.ReactInstanceManager;
^
C:\apps\react\showdriver\android\app\src\main\java\com\showdriver\MainApplication.java:8: error: package com.facebook.react does not exist
import com.facebook.react.ReactNativeHost;
^
C:\apps\react\showdriver\android\app\src\main\java\com\showdriver\MainApplication.java:9: error: package com.facebook.react does not exist
import com.facebook.react.ReactPackage;
^
C:\apps\react\showdriver\android\app\src\main\java\com\showdriver\MainApplication.java:10: error: package com.facebook.react.shell does not exist
import com.facebook.react.shell.MainReactPackage;
^
C:\apps\react\showdriver\android\app\src\main\java\com\showdriver\MainApplication.java:15: error: cannot find symbol
public class MainApplication extends Application implements ReactApplication {
^
 symbol: class ReactApplication
C:\apps\react\showdriver\android\app\src\main\java\com\showdriver\MainApplication.java:17: error: cannot find symbol
 private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) {
^
 symbol: class ReactNativeHost
 location: class MainApplication
C:\apps\react\showdriver\android\app\src\main\java\com\showdriver\MainApplication.java:30: error: cannot find symbol
 public ReactNativeHost getReactNativeHost() {
^
 symbol: class ReactNativeHost
 location: class MainApplication
C:\apps\react\showdriver\android\app\src\main\java\com\showdriver\MainActivity.java:11: error: method does not override or implement a method from a supertype
@Override
^
C:\apps\react\showdriver\android\app\src\main\java\com\showdriver\MainApplication.java:17: error: cannot find symbol
 private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) {
^
 symbol: class ReactNativeHost
 location: class MainApplication
12 errors
:app:compileDebugJavaWithJavac FAILED
July 2nd 19 at 14:04
2 answers
July 2nd 19 at 14:06
Try the console command:
react-native upgrade
then
react-native link
July 2nd 19 at 14:08
The most likely error is failures when automatically Linke. RNPM works well, but not always, so it is best in these types of errors (when connecting new modules) go through the instructions for manual installation https://github.com/rebeccahughes/react-native-devi...

If it's not srabotaet, roll back to working versions and install the module manually, it should help.

Find more questions by tags JavaScriptReact