We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Getting error after upgrade the library from 2.5.1 to 2.5.17
Provide the HTML code
Share the HTML code that you try to convert. <table style="" border="1" cellspacing="0" cellpadding="0" id="" data-mce-style="" class=""><thead style="" id="" data-mce-style="" class=""><tr style="" class="" id="" data-mce-style=""><th style="" scope="col" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class=""> </p></th><th style="" scope="col" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class=""> </p></th></tr></thead><tbody style="" id="" data-mce-style="" class=""><tr style="" class="" id="" data-mce-style=""><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Head 1</p></td><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Head 2</p></td></tr><tr style="" class="" id="" data-mce-style=""><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Data 1</p></td><td style="" valign="top" class="" id="" data-mce-style=""><table style="" border="1" cellspacing="0" cellpadding="0" id="" data-mce-style="" class=""><tbody style="" id="" data-mce-style="" class=""><tr style="" class="" id="" data-mce-style=""><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Sub head 1</p></td><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Sub head 2</p></td></tr><tr style="" class="" id="" data-mce-style=""><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Sub data 1</p></td><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Sub data 2</p></td></tr></tbody></table><p style="" id="" data-mce-style="" class=""> </p></td></tr><tr style="" class="" id="" data-mce-style=""><td style="" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">English EN -> short code 'E'<br style="" id="" data-mce-style="" class="">Chinese ZH -> short code '1' (one)<br style="" id="" data-mce-style="" class="">Russian RU -> short code 'R' <br style="" id="" data-mce-style="" class="">Japanese JA -> short code 'J'</p></td><td style="" class="" id="" data-mce-style=""><table style="" border="0" cellspacing="0" cellpadding="0" id="" data-mce-style="" class=""><colgroup style="" id="" data-mce-style="" class=""><col style="" span="2" id="" data-mce-style="" class=""></colgroup><thead style="" id="" data-mce-style="" class=""><tr style="" class="" id="" data-mce-style=""><td style="" align="right" class="" id="" data-mce-style="">1</td><td style="" align="right" class="" id="" data-mce-style="">2</td></tr><tr style="" class="" id="" data-mce-style=""><th style="" scope="col" align="right" class="" id="" data-mce-style="">3</th><th style="" scope="col" align="right" class="" id="" data-mce-style="">4</th></tr></thead></table><p style="" id="" data-mce-style="" class=""> </p></td></tr></tbody></table> Describe the bug A clear and concise description of what the bug is. What is the result in the PDF, versus what you expected to see. getting this error: Uncaught TypeError TypeError: Cannot read properties of undefined (reading 'getAttribute') at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:348:51) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:326:21) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:323:30) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at convertHtml (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:127:23) at htmlToPdfMake (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:1039:21) at module.exports (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:1054:10) at eval (repl:1:1)
<table style="" border="1" cellspacing="0" cellpadding="0" id="" data-mce-style="" class=""><thead style="" id="" data-mce-style="" class=""><tr style="" class="" id="" data-mce-style=""><th style="" scope="col" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class=""> </p></th><th style="" scope="col" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class=""> </p></th></tr></thead><tbody style="" id="" data-mce-style="" class=""><tr style="" class="" id="" data-mce-style=""><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Head 1</p></td><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Head 2</p></td></tr><tr style="" class="" id="" data-mce-style=""><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Data 1</p></td><td style="" valign="top" class="" id="" data-mce-style=""><table style="" border="1" cellspacing="0" cellpadding="0" id="" data-mce-style="" class=""><tbody style="" id="" data-mce-style="" class=""><tr style="" class="" id="" data-mce-style=""><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Sub head 1</p></td><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Sub head 2</p></td></tr><tr style="" class="" id="" data-mce-style=""><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Sub data 1</p></td><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Sub data 2</p></td></tr></tbody></table><p style="" id="" data-mce-style="" class=""> </p></td></tr><tr style="" class="" id="" data-mce-style=""><td style="" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">English EN -> short code 'E'<br style="" id="" data-mce-style="" class="">Chinese ZH -> short code '1' (one)<br style="" id="" data-mce-style="" class="">Russian RU -> short code 'R' <br style="" id="" data-mce-style="" class="">Japanese JA -> short code 'J'</p></td><td style="" class="" id="" data-mce-style=""><table style="" border="0" cellspacing="0" cellpadding="0" id="" data-mce-style="" class=""><colgroup style="" id="" data-mce-style="" class=""><col style="" span="2" id="" data-mce-style="" class=""></colgroup><thead style="" id="" data-mce-style="" class=""><tr style="" class="" id="" data-mce-style=""><td style="" align="right" class="" id="" data-mce-style="">1</td><td style="" align="right" class="" id="" data-mce-style="">2</td></tr><tr style="" class="" id="" data-mce-style=""><th style="" scope="col" align="right" class="" id="" data-mce-style="">3</th><th style="" scope="col" align="right" class="" id="" data-mce-style="">4</th></tr></thead></table><p style="" id="" data-mce-style="" class=""> </p></td></tr></tbody></table>
Uncaught TypeError TypeError: Cannot read properties of undefined (reading 'getAttribute') at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:348:51) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:326:21) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:323:30) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at convertHtml (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:127:23) at htmlToPdfMake (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:1039:21) at module.exports (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:1054:10) at eval (repl:1:1)
The text was updated successfully, but these errors were encountered:
Thanks for letting me know. I'm traveling these days. Except a few days before I can have a look at it.
Sorry, something went wrong.
6664c59
Fixed in v2.5.18
No branches or pull requests
Getting error after upgrade the library from 2.5.1 to 2.5.17
Provide the HTML code
Share the HTML code that you try to convert.
<table style="" border="1" cellspacing="0" cellpadding="0" id="" data-mce-style="" class=""><thead style="" id="" data-mce-style="" class=""><tr style="" class="" id="" data-mce-style=""><th style="" scope="col" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class=""> </p></th><th style="" scope="col" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class=""> </p></th></tr></thead><tbody style="" id="" data-mce-style="" class=""><tr style="" class="" id="" data-mce-style=""><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Head 1</p></td><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Head 2</p></td></tr><tr style="" class="" id="" data-mce-style=""><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Data 1</p></td><td style="" valign="top" class="" id="" data-mce-style=""><table style="" border="1" cellspacing="0" cellpadding="0" id="" data-mce-style="" class=""><tbody style="" id="" data-mce-style="" class=""><tr style="" class="" id="" data-mce-style=""><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Sub head 1</p></td><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Sub head 2</p></td></tr><tr style="" class="" id="" data-mce-style=""><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Sub data 1</p></td><td style="" valign="top" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">Sub data 2</p></td></tr></tbody></table><p style="" id="" data-mce-style="" class=""> </p></td></tr><tr style="" class="" id="" data-mce-style=""><td style="" class="" id="" data-mce-style=""><p style="" id="" data-mce-style="" class="">English EN -> short code 'E'<br style="" id="" data-mce-style="" class="">Chinese ZH -> short code '1' (one)<br style="" id="" data-mce-style="" class="">Russian RU -> short code 'R' <br style="" id="" data-mce-style="" class="">Japanese JA -> short code 'J'</p></td><td style="" class="" id="" data-mce-style=""><table style="" border="0" cellspacing="0" cellpadding="0" id="" data-mce-style="" class=""><colgroup style="" id="" data-mce-style="" class=""><col style="" span="2" id="" data-mce-style="" class=""></colgroup><thead style="" id="" data-mce-style="" class=""><tr style="" class="" id="" data-mce-style=""><td style="" align="right" class="" id="" data-mce-style="">1</td><td style="" align="right" class="" id="" data-mce-style="">2</td></tr><tr style="" class="" id="" data-mce-style=""><th style="" scope="col" align="right" class="" id="" data-mce-style="">3</th><th style="" scope="col" align="right" class="" id="" data-mce-style="">4</th></tr></thead></table><p style="" id="" data-mce-style="" class=""> </p></td></tr></tbody></table>
Describe the bug
A clear and concise description of what the bug is. What is the result in the PDF, versus what you expected to see.
getting this error:
Uncaught TypeError TypeError: Cannot read properties of undefined (reading 'getAttribute') at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:348:51) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:326:21) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:323:30) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at <anonymous> (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:191:29) at parseElement (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:190:22) at convertHtml (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:127:23) at htmlToPdfMake (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:1039:21) at module.exports (/Users/I500068/Desktop/works/Projects/Voyager/webapps/sr-pdf-srv/src/node_modules/html-to-pdfmake/index.js:1054:10) at eval (repl:1:1)
The text was updated successfully, but these errors were encountered: