Browser crashes when using toPng
Avence1 opened this issue · comments
import domtoimage from 'dom-to-image-more';
const img = document.querySelector('#PREVIEW_DOM_ID');
const config = {
width:296,
height:80,
bgcolor: 'transparent',
imagePlaceholder: 'fail',
cacheBust: false,
style: {
transformOrigin: 'top left',
transform: `scale(${window.devicePixelRatio})`,
width: '296px',
height: '80px',
},
};
domtoimage.toPng(img,config).then(url=>...)
Browser crashed when calling toPng function
Library version
3.2.0
Browsers
Chrome 90.0.4430.72