When trying to use domtoimage.toPng on HTML elements that encapsulates images, it returns an error "ERR_INSUFFICIENT RESOURCES" cannot fetch resource.
Root cause of issue After some debugging I have realized that it returns an error not because it cannot process the image but because there are too many images to process. How can I resolve this issue?
function convertToPng(page) {
return new Promise((resolve, reject) => {
//https://stackoverflow.com/questions/66306841/specific-file-on-aws-is-cors-blocked-when-using-domtoimage
let options = { "cacheBust":true }
resolve(domtoimage.toPng(page, options));
});
}