Changing:
const Jimp = require('jimp');
to
const {Jimp} = require('jimp');
worked for me in JavaScript.