What it does
- Compress Image By Reducing Resolution and Size
- Save original and compressed files to S3
- Contains Custom APIs to fetching saved files
A simple image compressor built with react, next.js and browser-image-compression
- ReactJS
- Next.js
- React Bootstrap
- Browser Image Compression
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
Need to install a software below to run the project on your local machine:
- Clone the repository and change directory.
git clone https://github.com/Mariam13/react-image-compressor
cd react-image-compressor
- Install npm dependencies
npm install
- To allow S3 uploading you should create a local environment file in the main directory and add all necessary configs to connect AWS Bucket
So, to create a local environment file run the following command on terminal
touch .env.local
After you should fill this AWS configurations
AWS_S3_BUCKET_NAME_ID=
AWS_S3_ACCESS_KEY_ID=
AWS_S3_SECRET_ACCESS_KEY=
- Run the app locally.
npm run dev
By default it will run on http://localhost:3000
server
If you want to build the app use "npm run build" command
You can find all the available APIs on this postman collection (click here)