loadFromLocal = async fileList =>
  await Promise.all(
    fileList.map(async file => {
      const {name, type, originFileObj} = file;
      if (type === 'text/csv') {
        const response = await parsePromise(originFileObj);
        return await response.data;
      } else if (name.endsWith('.arrow')) {
        const response = await parseArrow(originFileObj);
        return response;
      }
      /* eslint-disable no-console */
      console.warn(`${name} file format not supported.`);
      /* eslint-enable no-console */
    })
  )
a utility function that parses a list of uploaded files, asynchronously
currently, only .csv and .arrow files are supported.

example usage:
  loadFromLocal([
    'manifold/geo_partition.arrow',
    'manifold/geo_nopartition.arrow',
  ]).then(([partitionData, noPartitionData]) => {
     // use the loaded data here
  });

@param {[File]} fileList: a list of files
@return an array of promises with data parsed from the files