code: function getServerIpAddress(host, port) {
    if (host) {
      return `${host}:${port}`
    }
  
    if (isAndroid) {
      const FINGERPRINT = android.os.Build.FINGERPRINT
      if (FINGERPRINT.includes("vbox")) {
        // running on genymotion
        return `10.0.3.2:${port}`
      } else if (FINGERPRINT.includes("generic")) {
        // running on android emulator
        return `10.0.2.2:${port}`
      }
    }
  
    // ios simulator uses localhost
    return `127.0.0.1:${port}`
  }
docs: Returns the correct address for the host machine when running on emulator
  @param host
  @param port
  @returns {string}