Workaround to eliminate the warning:
Use:
import html2pdf from 'html2pdf.js/dist/html2pdf.min.js';
Instead of:
import html2pdf from 'html2pdf.js';
This is a known issue with the html2pdf.js library. See open issue for more details: https://github.com/eKoopmans/html2pdf.js/issues/570