oriio-js
Oriio JS SDK is a simple client-side file upload service that allows you to upload files directly from your web project to your storage or application setup with Oriio. Oriio's uploader is smart in that in takes into consideration file size to either upload your file the normal way or in chunks.
Features
- Upload files easily and efficiently.
- Add an
onProgress
handler to receive feedback on file progress. - Upload files to your own server.
Install
npm i oriio-js
Usage
import oriio from 'oriio-js';
const options = {
claimFile: {
url: 'url-of-your.server',
headers: { }, // headers for your server
}, // if claimFile object is passed the `openFileId` is automatically sent to your server.
concurrency: 3, // number of concurrent requests when chunk uploading
onProgress: handleUploadProgress,
}
oriio.upload(applicationId, options, file)
.then(onSuccess)
.catch(onError);