Install uppy in react javascript

29 Views Asked by At

I have installed the @uppy/core^3.7.1 @uppy/dashboard @uppy/react library but when I go to run the application, I get errors when compiling in the @uppy/utils/lib/getDroppedFiles/index.js library files such as Unexpected reserved word of the await in the function: export default async function getDroppedFiles(dataTransfer, options)

  var _options$logDropError;
  // Get all files from all subdirs. Works (at least) in Chrome, Mozilla, and Safari
  const logDropError = (_options$logDropError = options == null ? void 0 : options.logDropError) != null ? _options$logDropError : Function.prototype;
  try {
    const accumulator = [];
    for await (const file of webkitGetAsEntryApi(dataTransfer, logDropError)) {
      accumulator.push(file);
    }
    return accumulator;
    // Otherwise just return all first-order files
  } catch {
    return fallbackApi(dataTransfer);
  }
}

I hope you can help me to install uppy in javascript.

0

There are 0 best solutions below