title: React native custom component
body: <p>I am trying to use the ios toolbar and import it into a component to use for react native. I don't understand where I went wrong. I am getting the error "uknown module Toolkit.ios.js" when I use <code>var Tool = require('toolkit.ios.js');</code></p>
  
  <p>The file is there. What Am I missing here?
  I was trying to follow this tutorial here but with the toolbar component
  <a href="https://facebook.github.io/react-native/docs/native-components-ios.html#content" rel="nofollow">https://facebook.github.io/react-native/docs/native-components-ios.html#content</a></p>
  
  <pre><code> #import &lt;Foundation/Foundation.h&gt;
  
  @import UIKit;
  
  #import "RCTViewManager.h"
  
  @interface RCTToolBar : RCTViewManager
  @end
  
  @implementation RCTToolBar
  
  
  RCT_EXPORT_MODULE()
  
  - (UIView *)view
  {
    return [[UIToolbar alloc] init];
  }
  
  @end
  </code></pre>
  
  <p>// MapView.js</p>
  
  <pre><code>var React = require('react-native');
  var { requireNativeComponent } = React;
  
  // requireNativeComponent automatically resolves this to "RCTMapManager"
  
  class ToolBar extends React.Component {
    render() {
      return &lt;RCTToolBar /&gt;;
    }
  }
  
  module.exports = requireNativeComponent('RCTToolBar', ToolBar);
  </code></pre>
  
  <p>edit: messed up on copy and pasting code.</p>