title: React native app crashes due to some out of memory error how to fix this
body: <p>Because of the below error app crashes , i couldn't figure out what is the exact problem and what is the cause </p>
  
  <pre><code>java.lang.RuntimeException: 
        at com.facebook.react.bridge.JavaMethodWrapper.invoke (JavaMethodWrapper.java:383)
        at com.facebook.react.bridge.JavaModuleWrapper.invoke (JavaModuleWrapper.java:160)
        at com.facebook.react.bridge.queue.NativeRunnable.run (Native Method)
        at android.os.Handler.handleCallback (Handler.java:751)
        at android.os.Handler.dispatchMessage (Handler.java:95)
        at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage (MessageQueueThreadHandler.java:29)
        at android.os.Looper.loop (Looper.java:154)
        at com.facebook.react.bridge.queue.MessageQueueThreadImpl$3.run (MessageQueueThreadImpl.java:192)
        at java.lang.Thread.run (Thread.java:762)
      Caused by: java.lang.reflect.InvocationTargetException: 
        at java.lang.reflect.Method.invoke (Native Method)
        at com.facebook.react.bridge.JavaMethodWrapper.invoke (JavaMethodWrapper.java:372)
      Caused by: java.lang.OutOfMemoryError: 
        at java.lang.AbstractStringBuilder.&lt;init&gt; (AbstractStringBuilder.java:64)
        at java.lang.StringBuilder.&lt;init&gt; (StringBuilder.java:98)
        at libcore.net.UriCodec.decode (UriCodec.java:273)
        at android.net.Uri.decode (Uri.java:1946)
        at android.net.Uri$AbstractPart.getDecoded (Uri.java:1976)
        at android.net.Uri$StringUri.getSchemeSpecificPart (Uri.java:560)
        at cl.json.ShareFile.isBase64File (ShareFile.java:66)
        at cl.json.ShareFile.isFile (ShareFile.java:61)
        at cl.json.social.ShareIntent.open (ShareIntent.java:74)
        at cl.json.social.GenericShare.open (GenericShare.java:18)
        at cl.json.RNShareModule.open (RNShareModule.java:94)
  </code></pre>