Join our webinar on Wednesday, June 26, at 1pm EDTHow Chia Mitigates Risk in the Crypto Industry.Register
Socket
Socket
Sign inDemoInstall

@uppy/core

Package Overview
Dependencies
9
Maintainers
5
Versions
130
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @uppy/core

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:


Version published
Weekly downloads
223K
increased by6.78%
Maintainers
5
Created
Weekly downloads
 

Package description

What is @uppy/core?

@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.

What are @uppy/core's main functionalities?

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!');
  }
});

Other packages similar to @uppy/core

Readme

Source

@uppy/core

Uppy logo: a smiling puppy above a pink upwards arrow

npm version CI status for Uppy tests CI status for Companion tests CI status for browser tests

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.

  • Fetch files from local disk, remote urls, Google Drive, Dropbox, Instagram, or snap and record selfies with a camera;
  • Preview and edit metadata with a nice interface;
  • Upload to the final destination, optionally process/encode

Read the docs | Try Uppy

Uppy is being developed by the folks at Transloadit, a versatile file encoding service.

Example

import Uppy from '@uppy/core'

const uppy = new Uppy()
uppy.use(SomePlugin)

Installation

$ npm install @uppy/core

Alternatively, you can also use this plugin in a pre-built bundle from Transloadit’s CDN: Edgly. In that case Uppy will attach itself to the global window.Uppy object. See the main Uppy documentation for instructions.

Documentation

Documentation for this plugin can be found on the Uppy website.

License

The MIT License.

Keywords

FAQs

Last updated on 04 Jun 2024

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc