title: React Native 'require' statement resolves to a number when used in mapping
body: <p>I understand that require('') needs a static string, but when I try to map values in packaging to be used later in code </p>
  
  <pre><code>const BOXES2 = {
    silver: require('../../assets/imgs/status/silveroutline.png'),
    gold: require('../../assets/imgs/status/goldoutline.png'),
    platinum: require('../../assets/imgs/status/platinumoutline.png')
  }
  </code></pre>
  
  <p>they resolve to integers , the following logs the number 6</p>
  
  <pre><code>constructor(props) {
      super(props);
      var data = BOXES2[this.props.userData.memberStatus];
      console.log(data);
    }
  </code></pre>
  
  <p>so then I cannot load images like this</p>
  
  <pre><code>&lt;Image
          source={BOXES2[this.props.userData.memberStatus]}
          style={img}
          resizeMode="contain"
        /&gt;
  </code></pre>
  
  <p>memberStatus is a string value and the data and image paths are correct, as I can get it to work by creating a separate Image using each source path directly in render(), and then placing one of them in return() conditionally by the userData. </p>
  
  <p>I would like to figure the other way out though, as it requires many many less lines and much easier to maintain.</p>