Security News
JSR Working Group Kicks Off with Ambitious Roadmap and Plans for Open Governance
At its inaugural meeting, the JSR Working Group outlined plans for an open governance model and a roadmap to enhance JavaScript package management.
@uppy/core
Advanced tools
Core module for the extensible JavaScript file upload widget with support for drag&drop, resumable uploads, previews, restrictions, file processing/encoding, remote providers like Instagram, Dropbox, Google Drive, S3 and more :dog:
@uppy/core is a modular JavaScript file uploader that integrates with various file sources and provides a highly customizable and extensible API for handling file uploads.
File Selection
This feature allows users to select files from their local system using a customizable dashboard interface.
const Uppy = require('@uppy/core');
const Dashboard = require('@uppy/dashboard');
const uppy = Uppy();
uppy.use(Dashboard, {
inline: true,
target: 'body'
});
File Upload
This feature enables the uploading of selected files to a specified endpoint using XHR (XMLHttpRequest).
const Uppy = require('@uppy/core');
const XHRUpload = require('@uppy/xhr-upload');
const uppy = Uppy();
uppy.use(XHRUpload, {
endpoint: 'https://my-upload-endpoint.com/upload'
});
uppy.upload().then((result) => {
console.log('Upload complete:', result);
});
Progress Tracking
This feature provides a progress bar to track the upload progress of files.
const Uppy = require('@uppy/core');
const ProgressBar = require('@uppy/progress-bar');
const uppy = Uppy();
uppy.use(ProgressBar, {
target: 'body',
hideAfterFinish: false
});
File Validation
This feature allows for custom validation of files before they are uploaded, such as checking file size or type.
const Uppy = require('@uppy/core');
const uppy = Uppy();
uppy.on('file-added', (file) => {
if (file.size > 1000000) { // 1MB
uppy.removeFile(file.id);
alert('File is too large!');
}
});
Dropzone is a popular JavaScript library that provides drag-and-drop file uploads with image previews. It is less modular than @uppy/core but offers a simpler setup for basic use cases.
Fine Uploader is a comprehensive JavaScript library for file uploads that supports various features like chunking, retry, and concurrent uploads. It is more feature-rich but also more complex compared to @uppy/core.
Plupload is a JavaScript library that handles file uploads with support for multiple runtimes (HTML5, Flash, Silverlight, etc.). It is similar in functionality to @uppy/core but may require more configuration for advanced use cases.
Uppy is a sleek, modular JavaScript file uploader that integrates seamlessly with any application. It’s fast, provides a comprehensible API and lets you worry about more important problems than building a file uploader.
Uppy is being developed by the folks at Transloadit, a versatile file encoding service.
import Uppy from '@uppy/core'
const uppy = new Uppy()
uppy.use(SomePlugin)
$ npm install @uppy/core
Alternatively, you can also use this plugin in a pre-built bundle from
Transloadit’s CDN: Smart CDN. In that case Uppy
will attach itself to the
global window.Uppy
object. See the
main Uppy documentation for instructions.
Documentation for this plugin can be found on the Uppy website.
FAQs
Core module for the extensible JavaScript file upload widget with support for drag&drop, resumable uploads, previews, restrictions, file processing/encoding, remote providers like Instagram, Dropbox, Google Drive, S3 and more :dog:
The npm package @uppy/core receives a total of 212,170 weekly downloads. As such, @uppy/core popularity was classified as popular.
We found that @uppy/core demonstrated a healthy version release cadence and project activity because the last version was released less than 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.
Security News
At its inaugural meeting, the JSR Working Group outlined plans for an open governance model and a roadmap to enhance JavaScript package management.
Security News
Research
An advanced npm supply chain attack is leveraging Ethereum smart contracts for decentralized, persistent malware control, evading traditional defenses.
Security News
Research
Attackers are impersonating Sindre Sorhus on npm with a fake 'chalk-node' package containing a malicious backdoor to compromise developers' projects.