# react-s3-upload

> Easily upload files through S3 with minimal configuration

Latest version **0.1.6** (published 2016-03-20) · MIT license · 0 weekly downloads

## Install

```sh
npm install react-s3-upload
pnpm add react-s3-upload
yarn add react-s3-upload
bun add react-s3-upload
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.6 |
| Published | 2016-03-20 |
| First published | 2016-02-29 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 5 |
| Author | Jan Jorissen |
| Maintainers | mordhau |
| Keywords | react, s3, amazon |

## Links

- npm: https://www.npmjs.com/package/react-s3-upload
- Repository: https://github.com/Qaaj/react-s3-upload
- Homepage: https://github.com/Qaaj/react-s3-upload#readme
- Issues: https://github.com/Qaaj/react-s3-upload/issues
- npm.io page: https://npm.io/package/react-s3-upload

## Alternatives

- [mobx-react](https://npm.io/package/mobx-react.md) — 2.8M weekly downloads
- [rc-tree](https://npm.io/package/rc-tree.md) — 2.6M weekly downloads
- [@react-oauth/google](https://npm.io/package/@react-oauth/google.md) — 1.3M weekly downloads
- [@wagmi/connectors](https://npm.io/package/@wagmi/connectors.md) — 877.0K weekly downloads
- [vee-validate](https://npm.io/package/vee-validate.md) — 836.4K weekly downloads

## Recent versions

- 0.1.6 (latest) — 2016-03-20
- 0.1.5 — 2016-03-11
- 0.1.42 — 2016-02-29
- 0.1.41 — 2016-02-29
- 0.1.4 — 2016-02-29
- 0.1.3 — 2016-02-29
- 0.1.2 — 2016-02-29
- 0.1.1 — 2016-02-29
- 0.1.0 — 2016-02-29
- 0.0.5 — 2016-02-29
- 0.0.3 — 2016-02-29
- 0.0.2 — 2016-02-29
- 0.0.1 — 2016-02-29

## README

# react-s3-upload

This library allows you to very easily upload files from a react application to Amazon S3, using express for authing with S3 and signing.

The component is completely stateless, so while it functions as a React component, there's no dependency on the React framework for this package.

Actually, this package has no hard dependencies - it does, however, assume you have aws-sdk configured on your express server.

Library was created following the tutorial available on Heroku - https://devcenter.heroku.com/articles/s3-upload-node

  - Embed the react component in your application
  - Set up your express server
  - Magic

# Installation

    $ npm install react-s3-upload

# React Component

    import ReactUpload from 'react-s3-upload';

    <ReactUpload 
      onProgress={ (pct) => { console.log(pct) } }
      onComplete={ (url) => { console.log(url) } }
      folder="uploads" />

  - `onProgress` - callback function for XHR onprogress.
  - `onComplete` - callback function when upload is done.
  - `folder` - [optional] folder in your bucket where the file will be uploaded to.

# Server-Side

     app.get('/sign_s3', require('react-s3-upload/S3Sign')({
        S3_BUCKET:'your_bucket', 
        unique: false
      }));

  - `unique` - [optional] generate a unique filename for your upload or not.
  - `S3_BUCKET` - the name of your Amazon S3 bucket.

---
_Source: https://npm.io/package/react-s3-upload · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
