title: html2pdf not respecting div width and height explicitly set
body: <p>I am building my div element and putting it inside the html2pdf library (<a href="https://github.com/eKoopmans/html2pdf.js/blob/master/README.md" rel="nofollow noreferrer">link</a>) when I generate the PDF. I am generating the size for the div element with such JS logic:</p>
  
  <pre><code>switch (sizeSelected) {
      case '3x5':
          canvasSizeObj.width = 288;
          canvasSizeObj.height = 480;
          break;
      case '4x6':
          canvasSizeObj.width = 384;
          canvasSizeObj.height = 576;
          break;
      case '5x7':
          canvasSizeObj.width = 480;
          canvasSizeObj.height = 672;
          break;
      case '8x8':
          canvasSizeObj.width = 768;
          canvasSizeObj.height = 768;
          break;
  }
  
  var divContent = document.createElement('div'),
      popupDOMContent = document.createElement('div');
  
      divContent.classList.add('popupDOMContent');
      divContent.setAttribute('style','height:'+canvasSizeObj.height+'px');
      divContent.setAttribute('style','width:'+canvasSizeObj.width+'px');
      document.body.appendChild(divContent);
      popupDOMContent.classList.add('popupDOMContent');
  
  html2pdf()
      .set({filename:petName+'_Kennel_Card_'+sizeSelected+'.pdf',margin:1})
      .from(popupDOMContent)
      .save();
  
  popupDOMContent.remove();
  </code></pre>
  
  <p>I can see the element on the body if I choose to not remove it, and I can see the size is set for the element in below screenshot:
  <a href="https://i.stack.imgur.com/j2AS8.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/j2AS8.png" alt="enter image description here"></a></p>
  
  <p>But when I open up the PDF, it is not honoring that size and instead full width, as seen in below screenshot:
  <a href="https://i.stack.imgur.com/yDJjq.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/yDJjq.png" alt="enter image description here"></a></p>
  
  <p>What am I missing here?</p>