devgeeks/Canvas2ImagePlugin

Ionic2 support

Opened this issue · 1 comments

Is there any support for Ionic2 with typescript ?

my current quick solution for Canvas2ImagePlugin typescript and Canvas2ImagePlugin ionic2 is
and it is working successfully

let _widow:any = window ;

    if (_widow.cordova) {
      console.log('cordova attached');
      // running on device/emulator
      _widow.canvas2ImagePlugin.saveImageDataToLibrary(
        function(msg){
          console.log(msg);

        },
        function(err){
          console.log(err);

        },
        this.canvasAngularElementRef.nativeElement
      );
    }