Skip to main content

@rpldy/tus-uploady

Installation

npm install @rpldy/tus-uploady

Details

This package is provided as a convenient alternative to the main Uploady package. To be used in case resumable (tus) upload is required.

Internally, TusUploady uses @rpldy/tus-sender instead of the default (XHR) sender.

TUS Protocol

On top of the Core Protocol, Uploady supports the following extensions:

It also supports the Upload-Metadata header and will turn the destination params prop into the metadata key/value.

Example

TUS - Simple Example
 import React from "react";
import TusUploady from "@rpldy/tus-uploady";
import UploadButton from "@rpldy/upload-button";

const App = () => (<TusUploady
destination={{ url: "https://my-tus-server/upload" }}
chunkSize={2142880}
sendDataOnCreate
>
<UploadButton/>
</TusUploady>);

Exports

info

Plus all the exports from uploady