UNPKG

png-upload-optimizer

Version:

Simple PNG Image Upload optimizer for frontend that scales your image as per your usability

17 lines (12 loc) 546 B
# png-upload-optimizer [png-upload-optimizer](https://github.com/amanshrt/png-optimizer) is the simple solution for optimizing the upload of the png files by scaling down the image as per your command. ## Steps Involved: 1. Converts the uploaded file to string URL 2. Then converts it to HTMLPageElement 3. After that, it converts image to canvas and main resizing/scaling task is done here. 4. Converts back to Unit8Array and back to png file ## Getting Started ### Install `npm i png-upload-optimizer ` or, `yarn add png-upload-optimizer`