Call the print method in the Table of antd and find that the printed data is not aligned with js

due to the need to add printing function, that is, to bring up the printer"s pop-up window interface, it just so happens that the form uses the antd table, and I find that no matter which node I put the id of printTable on, I will not align the form

the following code calls up the print function interface

var tableToPrint = document.getElementById("printTable");//
var newWin= window.open("");//
newWin.document.write(tableToPrint.outerHTML);//
newWin.document.close();//IE
newWin.focus();//IE
newWin.print();//
newWin.close();//

the following picture shows one of the Table Demo on antd"s official website

https://codesandbox.io/s/jn3yj82nm3


you just put html in a new window, but css doesn't have

.

pay attention to this sentence:

  print < / Link > 
)
}

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1be2d94-3163b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1be2d94-3163b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?