Native js printing, how to customize the page size with js, ask for advice, thank you very much! (native js print customization problem)

the existing functions such as printing and automatic paging have been implemented with native js, but the paper size cannot be customized. I do not want to set the paper size on the preview page manually, and the given paper size does not meet the business requirements

.
Apr.05,2021

not everything can / should be controlled by code. Printing function does not belong to js , but belongs to WEB API , so there is no such function in WEB API .
personally, I think you are just providing services, and you should not choose whether it is color typing / black and white or A4/A5 . You don't even know whether the user's printer supports or what habits the user has, whether he is nearsighted or presbyopia. If you need that dimension style, you can configure your own default style.

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-1e5df71-45762.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-1e5df71-45762.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?