ItsY8S / capstone

0 stars 0 forks source link

Image Uploading & Resizing #4

Open ItsY8S opened 5 years ago

ItsY8S commented 5 years ago

I want to use Jimp alongside Multer and UUID to handle the uploading and resizing of images and create unique file names.

Resources

Multer

Multer is a middleware that adds a 'file' object to the request of the body. You can choose to use multiple fields or just select one. Must also use 'multipart/form-data' to properly accept files. Another thing Multer does is allow you to set configuration options to the upload.

UUID

UUID can generate unique id's for a variety of different things. This will help me to name my images without running into the problem of duplicate file names.

Jimp

Jimp allows you to resize and change the quality of images. Supported types include .jpeg, .png, .gif, .bpm, & .tiff. Images can be read from buffer or from memory. It also supports a variety of methods such as cropping, flipping, and rotating.