Using React Native to develop an Android app for billing purposes, I encountered an issue with the output paper size being 216mmX279mm instead of the standard PDF size of 210mmX297mm.
Utilizing expo-print
and printToFileAsync
from expo, I aim to achieve a PDF output in A4 size (210mmX297mm).
https://i.stack.imgur.com/qrDHl.png
After researching at the expo print
documentation and referring to .@page docs on MDN website,
I am left wondering:
How do I Change Output to A4 size?
Examination of the print Documentation reveals mentions of FilePrintOptions
,
stating:
The default height of a single page is 792 pixels, equivalent to the US Letter paper format with 72 PPI. https://i.stack.imgur.com/F9edP.png
So How Can I change the defaults to A4 size and increase DPI?