title: React Native: Dynamic Bottom-Sheet
body: <p>Hello I want to build a FlatList with several items and each of them should open a bottom-sheet. To realize this I want to do it dynamic. But I get an error.<br></p>
  
  <p><code>TypeError: undefined is not an object (evaluating `_this[_reactNativeRawBottomSheet.default + index]= _ref2`)</code></p>
  
  <pre><code>import RBSheet from "react-native-raw-bottom-sheet";
  
  
  function Test({ navigation }) {
    const index = 0;
    return (
      &lt;View style={styles.containerMain}&gt;
  
        &lt;View&gt;
          &lt;Button
            title={`OPEN BOTTOM SHEET ${index}`}
            onPress={() =&gt; this[RBSheet + index].open()}
          /&gt;
          &lt;RBSheet
            ref={(ref) =&gt; {
              this[RBSheet + index] = ref;
            }}
          &gt;
            &lt;Text&gt;I am {index}&lt;/Text&gt;
            &lt;Button title="close" onPress={() =&gt; this[RBSheet + index].close()} /&gt;
          &lt;/RBSheet&gt;
        &lt;/View&gt;
  
      &lt;/View&gt;
    );
  }
  
  export default Test;
  </code></pre>