You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi good morning, I would like to ask help because I'm a newbie in react and I only know how to add package in new ways.
Can anyone help me how to add this package in new react native way heres the sample code
`public class MainActivity extends ReactActivity {
/**
* Returns the name of the main component registered from JavaScript.
* This is used to schedule rendering of the component.
*/ @OverRide
protected String getMainComponentName() {
return "sampleproject";
}
}
public class MainApplication extends Application implements ReactApplication {
private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) { @OverRide
protected boolean getUseDeveloperSupport() {
return BuildConfig.DEBUG;
} @OverRide
protected List getPackages() {
return Arrays.asList(
new MainReactPackage(),
new VectorIconsPackage(),
new WebRTCModulePackage()
);
}
};
@OverRide
public ReactNativeHost getReactNativeHost() {
return mReactNativeHost;
}
Hi good morning, I would like to ask help because I'm a newbie in react and I only know how to add package in new ways.
Can anyone help me how to add this package in new react native way heres the sample code
`public class MainActivity extends ReactActivity {
/**
* Returns the name of the main component registered from JavaScript.
* This is used to schedule rendering of the component.
*/
@OverRide
protected String getMainComponentName() {
return "sampleproject";
}
}
public class MainApplication extends Application implements ReactApplication {
private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) {
@OverRide
protected boolean getUseDeveloperSupport() {
return BuildConfig.DEBUG;
}
@OverRide
protected List getPackages() {
return Arrays.asList(
new MainReactPackage(),
new VectorIconsPackage(),
new WebRTCModulePackage()
);
}
};
@OverRide
public ReactNativeHost getReactNativeHost() {
return mReactNativeHost;
}
@OverRide
public void onCreate() {
super.onCreate();
SoLoader.init(this, /* native exopackage */ false);
}
}
`
Please help me for solving my problem thanks!
The text was updated successfully, but these errors were encountered: