title: How do I access the react-native-camera's video capabilities?
body: <p>I've been attempting to get the react-native-camera's video feature to work, but and have tried a vast number of methods but keep getting the same errors.  Here is my code:</p>
  
  <pre><code>class MainCamera extends Component {
    constructor() {
    super();
    this.render = this.render.bind(this)
    this.state = { cameraType: Camera.constants.Type.back }
  }
  
    render() {
  
  return (
    &lt;View style={styles.container}&gt;
      &lt;Camera
        ref='camera'
        style={styles.preview}
        aspect={Camera.constants.Aspect.fill}
        type={this.state.cameraType}
        captureMode={Camera.constants.CaptureMode.video}
        captureAudio={false}
        target={Camera.constants.CaptureTarget.disk}&gt;
  
        &lt;TouchableHighlight
          onPressIn={this.onPressIn.bind(this)}
          onPressOut={this.stopVideo.bind(this)}&gt;
          &lt;Icon name="video-camera" size={40} /&gt;
        &lt;/TouchableHighlight&gt;
      &lt;/Camera&gt;
    &lt;/View&gt;
  );
    }
  
  onPressIn() {
    recordVideo = setTimeout(this.takeVideo.bind(this), 100);
  }
  
  takeVideo() {
      this.refs.camera.capture({
        target: Camera.constants.CaptureTarget.disk
      })
        .then(data =&gt; {
          console.log(data);
        })
        .catch(err =&gt; console.log(err));
    }
  
  stopVideo() {
    this.refs.camera.stopCapture({})
      .then(data =&gt; console.log(data))
      .catch(err =&gt; console.log(err));
    }
  }
  </code></pre>
  
  <p>When I use the '.then' promise on the stopCapture() method, I receive the error "Cannot read property 'then' of undefined", but if I don't add the '.then', then nothing happens and I don't receive any data.  Does anybody have any suggestions?</p>