react-pdf
react-pdf copied to clipboard
dpi is not prop of Page
Describe the bug Try to change dpi of a page and following TypeScript error.
No overload matches this call.
Overload 1 of 2, '(props: PageProps | Readonly<PageProps>): Page', gave the following error.
Type '{ children: Element[]; size: "A4";wrap: false; dpi: number; }' is not assignable to type 'IntrinsicAttributes & IntrinsicClassAttributes<Page> & Readonly<PageProps>'.
Property 'dpi' does not exist on type 'IntrinsicAttributes & IntrinsicClassAttributes<Page> & Readonly<PageProps>'.
Overload 2 of 2, '(props: PageProps, context: any): Page', gave the following error.
Type '{ children: Element[]; size: "A4"; wrap: false; dpi: number; }' is not assignable to type 'IntrinsicAttributes & IntrinsicClassAttributes<Page> & Readonly<PageProps>'.
Property 'dpi' does not exist on type 'IntrinsicAttributes & IntrinsicClassAttributes<Page> & Readonly<PageProps>'.ts(2769)
To Reproduce Steps to reproduce the behavior including code snippet (if applies):
- Create a TypeScript project.2.
- Try to use dpi prop of Page component.3. 3.
Expected behavior Should be able to use dpi prop of the Page component in TypeScript .
Desktop (please complete the following information):
- OS: MacOS
- React-pdf version : 2.3.0