Node-html-pdf: Flex is not Wroking

Created on 12 Sep 2020  路  4Comments  路  Source: marcbachmann/node-html-pdf

I am using Flex for styling the html but it is not working in the pdf.

Most helpful comment

I found this answer from StackOverflow very helpful, just add -webkit prefix to all your flex properties. I tried it out and it worked perfectly for me!

display: -webkit-flex;
-webkit-flex-direction: row;
-webkit-flex: 1;

All 4 comments

add this css
display: -webkit-box;
display: -webkit-flex;
-webkit-flex-wrap: wrap;
display: flex;
flex-wrap: wrap;

add this in package.json

       "browserslist": [
"Safari >=4"

]

I found this answer from StackOverflow very helpful, just add -webkit prefix to all your flex properties. I tried it out and it worked perfectly for me!

display: -webkit-flex;
-webkit-flex-direction: row;
-webkit-flex: 1;

You can use float instead of flexbox or grid.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

RodolfoSilva picture RodolfoSilva  路  3Comments

Mortuie picture Mortuie  路  4Comments

jimit-hothi picture jimit-hothi  路  4Comments

tashikomaaa picture tashikomaaa  路  5Comments

qianweicheng picture qianweicheng  路  5Comments