
Research
Security News
The Growing Risk of Malicious Browser Extensions
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
@99xt/react-fileupload
Advanced tools
Simpler file upload implementation for react.js apps.
To install this library, run:
npm install @99xt/react-fileupload --save
example.component.js
import React, {Component} from 'react';
import FileUpload from '@99xt/react-fileupload';
class ExampleApp extends Component {
onUploadFiles(evt) {
if (evt.error) {
throw evt.error;
}
const files = evt.files;
// You can run upload script here
console.log(files);
}
render() {
const allowedTypes = [];
const allowedSize = 15; // MB
const multiple = true;
return (
<div>
<h1>react-fileupload Demo</h1>
{ /* with default UI */ }
<FileUpload
allowedTypes={ allowedTypes }
allowedSize={ allowedSize }
multiple={ multiple }
onUploadFiles={ this.onUploadFiles }
/>
{ /* with custom UI */ }
<FileUpload
allowedTypes={allowedTypes}
allowedSize={allowedSize}
multiple={multiple}
onUploadFiles={this.onUploadFiles}
renderUI={props => {
const { status } = props;
return (
<div style={{ border: "2px dashed #ccc", padding: "50px" }}>
<p>Click or drag n drop your file(s) here.</p>
<p>Drag n drop status: {status}</p>
</div>
);
}}
/>
</div>
);
}
}
Clone the repository to your workstation
git clone git@github.com:99xt/react-fileupload.git
Navigate to the project directory
cd react-fileupload
npm install
npm run build
Use npm run clean
for delete built resources.
npm start
Demo app will start on http://localhost:3000
Update the version in package.json
;
npm publish
MIT
FAQs
react-fileupload React component
The npm package @99xt/react-fileupload receives a total of 2 weekly downloads. As such, @99xt/react-fileupload popularity was classified as not popular.
We found that @99xt/react-fileupload demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 5 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
Research
Security News
An in-depth analysis of credential stealers, crypto drainers, cryptojackers, and clipboard hijackers abusing open source package registries to compromise Web3 development environments.
Security News
pnpm 10.12.1 introduces a global virtual store for faster installs and new options for managing dependencies with version catalogs.