npm.io
0.0.5 • Published 6 years ago

image-simple-resize

Licence
ISC
Version
0.0.5
Deps
2
Size
10 kB
Vulns
4
Weekly
0

Image simple resize

How to use

  • npm install -D
  • add image files to a directory.
  • import the package const imgSimpleResizer = require('image-simple-resize')
  • imgSimpleResizer function takes 2 arguments:
    • pathToImages: string use path.join(__dirname, path_to_your_images)
    • options: Options
      • awsConfig: AWSConfig {bucket: string; accessKeyId: string; secretAccessKey: string;}
      • imageSizes: ImageSizes {thumbnail?: number; product?: number; origin?: number;}
      • useWebp: boolean
  • see your optimized files in the AWS S3 bucket