Gathering detailed insights and metrics for @rpldy/shared-ui
Gathering detailed insights and metrics for @rpldy/shared-ui
Gathering detailed insights and metrics for @rpldy/shared-ui
Gathering detailed insights and metrics for @rpldy/shared-ui
Modern file uploading - components & hooks for React
npm install @rpldy/shared-ui
Typescript
Module System
Node Version
NPM Version
96.1
Supply Chain
78.5
Quality
81
Maintenance
100
Vulnerability
100
License
JavaScript (95.58%)
TypeScript (3.62%)
HTML (0.57%)
MDX (0.22%)
Shell (0.02%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
MIT License
1,178 Stars
953 Commits
40 Forks
7 Watchers
6 Branches
12 Contributors
Updated on Jul 11, 2025
Latest Version
1.10.0
Package Id
@rpldy/shared-ui@1.10.0
Unpacked Size
57.66 kB
Size
10.79 kB
File Count
41
NPM Version
lerna/8.2.2/node@v20.15.1+x64 (linux)
Node Version
20.15.1
Published on
Apr 18, 2025
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
2
1
4
Modern file-upload components & hooks for React.
React-Uploady is a lightweight library - enabling you to build (client-side) file-upload features with just a few lines of code. Uploady provides the foundations needed to upload files from the browser - The rest is up to you.
The philosophy behind this library is that it should be as simple as possible to use, yet customizable at every point. You can start simple, or you can configure just about every aspect of the upload flow. For this purpose, there are components, hooks, and plenty of features. You get to choose which ones you need and only install the dependencies required (See Packages details below)
React-Uploady has a small footprint (by design) with very few (tiny) dependencies.
Bundle | Minified size | GZipped size |
---|---|---|
core | 29.1KB | 10.5KB |
core + ui | 36.9KB | 13.3KB |
core + ui + chunked support | 44.1KB | 15.7KB |
everything | 71.0KB | 22.9KB |
The best place to get started is at our: React-Uploady Documentation Website
Another great place to learn about React-Uploady is our video series on Youtube.
For a list of versions and changes, see the CHANGELOG
Please check the discussions area here in Github. If you have a question about use-cases or flows you'd like to achieve with Uploady, discussions is the place to look for existing answers or add your own.
If you're using Uploady in Production, please drop a comment here. It's always great to hear how people and companies use it.
React-uploady is a mono-repo, and as such provides multiple packages with different functionality.
For React applications, at the very least, you will need the Uploady provider:
1#Yarn: 2 $ yarn add @rpldy/uploady 3 4#NPM: 5 $ npm i @rpldy/uploady
If you wish to use the uploading mechanism (no UI), at the very least, you will need the Uploader:
1#Yarn: 2 $ yarn add @rpldy/uploader 3 4#NPM: 5 $ npm i @rpldy/uploader
After that, you can add additional packages as needed. See below for more details.
For specific usage, see documentation in the relevant package README file.
For upload options, see the @rpldy/uploady docs.
This example shows how you add Uploady and UploadButton to your app. This is all it takes to get file uploading to work in your React application.
1 2import React from "react"; 3import Uploady from "@rpldy/uploady"; 4import UploadButton from "@rpldy/upload-button"; 5 6const App = () => (<Uploady 7 destination={{ url: "https://my-server/upload" }}> 8 <UploadButton/> 9</Uploady>); 10
In case you want to use your own component as the upload trigger, use the asUploadButton HOC:
1 2import React from "react"; 3import Uploady from "@rpldy/uploady"; 4import { asUploadButton } from "@rpldy/upload-button"; 5 6const DivUploadButton = asUploadButton((props) => { 7 return <div {...props} style={{ cursor: "pointer" }}> 8 DIV Upload Button 9 </div> 10}); 11 12const App = () => (<Uploady 13 destination={{ url: "https://my-server/upload" }}> 14 <DivUploadButton/> 15</Uploady>); 16
1 2import React from "react"; 3import Uploady, { useItemProgressListener } from "@rpldy/uploady"; 4import UploadButton from "@rpldy/upload-button"; 5 6//must be rendered inside <Uploady> 7const LogProgress = () => { 8 useItemProgressListener((item) => { 9 console.log(`>>>>> (hook) File ${item.file.name} completed: ${item.completed}`); 10 }); 11 12 return null; 13} 14 15const App = () => (<Uploady 16 destination={{ url: "https://my-server/upload" }}> 17 <LogProgress/> 18 <UploadButton/> 19</Uploady>); 20
1 import React from "react"; 2 import TusUploady from "@rpldy/tus-uploady"; 3 import UploadButton from "@rpldy/upload-button"; 4 5 const App = () => (<TusUploady 6 destination={{ url: "https://my-tus-server/upload" }} 7 chunkSize={2142880} 8 sendDataOnCreate> 9 <UploadButton/> 10 </TusUploady>);
Can be used with servers that support chunked uploads
1import React from "react"; 2import ChunkedUploady from "@rpldy/chunked-uploady"; 3import UploadButton from "@rpldy/upload-button"; 4 5const App = () => (<ChunkedUploady 6 destination={{ url: "https://my-server/upload" }} 7 chunkSize={5242880}> 8 9 <UploadButton/> 10</ChunkedUploady>); 11
These are the options that are passed to the uploader to configure aspects of the upload process. For example, whether files can be grouped in a single request (by default, no).
Upload Options are typically passed to the Uploady instance. But these can be overridden. For example, by props passed to the upload button. Or even during upload processing.
Passed as a part of the upload options. It's an object that is used to configure the end-point where the files will be uploaded to. Its type is defined here.
See more information in the Uploady doc.
At the very least, a destination should contain a URL property with the server endpoint.
1 2(uploader: UploaderType, trigger: Trigger<mixed>) => UploaderType
Enhancers are functions that can enhance an uploader instance. They are also passed as part of the options given to the Uploady instance.
As they are applied when the uploader instance is created, they can change the way uploader does things or pass different defaults.
See this guide for practical information and sample code.
When a file or files are handed over to the uploader, they are grouped into a batch. This batch will have its own lifetime events. With a batch ID, it is possible to cancel all files that are part of it. It can also be used to retry all files in the batch (see @rpldy/retry).
Each file (or URL) added to the uploader is wrapped by a BatchItem object. They will have a unique ID within the life-time of the uploader instance. A BatchItem has its own lifetime events.
Uploady supports resumable uploads through the tus protocol. Instead of using <Uploady> from @rpldy/uploady, use <TusUploady> from @rpldy/tus-uploady and you will have resumable upload support on the client side. Your server will also have to support the same protocol for this to work, of course.
See the @rpldy/tus-uploady documentation for more details.
React-uploady is also available on CDNs such as unpkg.com and jsdelivr.com
See this guide for more information on how to use.
You will most likely need the polyfill (core js) bundle as well (load it first):
You will most likely need the polyfill (core js) bundle as well (load it first):
Note that unpkg does a redirect to the latest version in case the URL doesn't already contain it. So don't copy any of the URLs above into your code. Instead, load them in the browser first and then copy the final URL from there (after the redirect).
Show Uploady your support by giving us a ⭐.
If you'd like to help Uploady grow & improve, take a look at the Contributing doc.
The Discussions page is a great place to ask questions, raise ideas and interact with Uploady maintainer, users and contributors.
Already using Uploady in Production? Let us know how & where in this open discussion.
Companies/Organizations that have contributed to the project:
Want to help sustain and grow Uploady? You can become a financial backer on OpenCollective.
Become a financial contributor and help us sustain our community.
You can make a one-time contribution or on a monthly basis
Or just buy me a coffee 😄
logo's wing thanks to Illustration Vectors by Vecteezy
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
21 commit(s) and 3 issue activity found in the last 90 days -- score normalized to 10
Reason
security policy file detected
Details
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
SAST tool is run on all commits
Details
Reason
5 existing vulnerabilities detected
Details
Reason
Found 1/23 approved changesets -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
project is not fuzzed
Details
Score
Last Scanned on 2025-07-07
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More