title: How to convert image type to 'jpg' using imagemagick in node.js
body: <p>I am using imagemagick in my node.js app. I have resized the image as follows:</p>
  
  <pre><code>im.resize({
          format: 'jpg',
          srcPath: imagePath,
          dstPath: thumbPath,
          width: 220,
          }, function(err, stdout, stderr){
          //some code
         }
  });
  </code></pre>
  
  <p>I want my code to convert the incoming images to <code>jpg</code>. How can I achieve this?</p>