Here’s the minimal amount of work you need to do to create a Native UI component called MyBasicView in an Android React Native application.

Create a ViewManager subclass to instantiate the view. Subclassing from SimpleViewManager<T> automatically gives you some basic support for styling the view.

android/app/src/main/java/com/example/MyBasicViewManager.java

package com.example;

import android.view.View;
import com.facebook.react.uimanager.SimpleViewManager;
import com.facebook.react.uimanager.ThemedReactContext;

public class MyBasicViewManager extends SimpleViewManager<View>
{
  @Override
  public String getName()
  {
    return "MyBasicView";
  }

  @Override
  public View createViewInstance(ThemedReactContext context)
  {
    return new View(context);
  }
}

Next create a ReactPackage to package to bundle up all the native stuff we write: in this case, only MyBasicView:

android/app/src/main/java/com/example/MyReactPackage.java

package com.example;

import java.util.List;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Arrays;

import com.facebook.react.ReactPackage;
import com.facebook.react.bridge.NativeModule;
import com.facebook.react.bridge.ReactApplicationContext;
import com.facebook.react.bridge.JavaScriptModule;
import com.facebook.react.uimanager.ViewManager;

class MyReactPackage implements ReactPackage
{
  @Override
  public List<NativeModule> createNativeModules(ReactApplicationContext reactContext)
  {
    return Collections.emptyList();
  }

  @Override
  public List<Class<? extends JavaScriptModule>> createJSModules()
  {
    return Collections.emptyList();
  }

  @Override
  public List<ViewManager> createViewManagers(ReactApplicationContext reactContext)
  {
    return Arrays.<ViewManager>asList(
      new MyBasicViewManager()
    );
  }
}

And finally we add an instance of the package during our main activity’s onCreate which in turn makes available our MyBasicView UI component:

android/app/src/main/java/com/example/MainActivity.java

public class MainActivity extends Activity implements DefaultHardwareBackBtnHandler {
{
  // ...

  @Override
  protected void onCreate(Bundle savedInstanceState)
  {
    super.onCreate(savedInstanceState);
    mReactRootView = new ReactRootView(this);

    mReactInstanceManager = ReactInstanceManager.builder()
      .setApplication(getApplication())
      .setBundleAssetName("index.android.bundle")
      .setJSMainModuleName("index.android")
      .addPackage(new MainReactPackage())
      .addPackage(new MyReactPackage())
      .setUseDeveloperSupport(BuildConfig.DEBUG)
      .setInitialLifecycleState(LifecycleState.RESUMED)
      .build();

    mReactRootView.startReactApplication(mReactInstanceManager, "MyAppName", null);

    setContentView(mReactRootView);
  }

  // ...
}

Now we can instantiate the view on the JavaScript side:

React = require('react-native');
MyBasicView = React.requireNativeComponent("MyBasicView");

MyComponent = React.createClass({
  render: function() {
    style = {
      width: 50,
      height: 50,
      backgroundColor: "red"
    };

    return <MyBasicView style={style} />;
  }
});