0

In below convert method i need to add callback method.How can i do that.

 var imagemagick = require('imagemagick-native');
 var srcData     = require('fs').readFileSync('./test/test.png'); 

 imagemagick.convert({
       srcData: srcData, 
       width: 100,
       height: 100,
       resizeStyle: "aspectfill",
       quality: 80,
      format: 'JPEG'
  });
sachin
  • 13,605
  • 14
  • 42
  • 55

1 Answers1

1

In imagemagick-native, method convert is synchronous, and does not require any callback to be defined.

moka
  • 22,846
  • 4
  • 51
  • 67