Image Resizer

Contents

Cordova Plugin For Image Resize

https://github.com/JoschkaSchulz/cordova-plugin-image-resizer

Stuck on a Cordova issue?

Installation

Community Enterprise
ionic cordova plugin add info.protonet.imageresizer npm install @ionic-native/image-resizer
Ionic EE comes with fully supported and maintained plugins from the Ionic Team. Learn More   or   Contact Us
ionic enterprise register --key=YOURPRODUCTKEY npm install @ionic-enterprise/image-resizer

Supported Platforms

  • Android
  • iOS
  • Windows

Usage

import { ImageResizer, ImageResizerOptions } from '@ionic-native/image-resizer/ngx';

constructor(private imageResizer: ImageResizer) { }

...

let options = {
 uri: uri,
 folderName: 'Protonet',
 quality: 90,
 width: 1280,
 height: 1280
} as ImageResizerOptions;

this.imageResizer
  .resize(options)
  .then((filePath: string) => console.log('FilePath', filePath))
  .catch(e => console.log(e));