You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I understand that React-PDF does not aim to be a fully-fledged PDF viewer and is only a tool to make one
I have checked if this feature request is not already reported
Description
I would like to get a new renderer besides SVG and Canvas, as I would like to use plain images as a render mode (which I belive is what canvas is doing under the hood).
The final goal is to create a renderer that includes the page as multiple chunks of images (512x512px max) so that it can be lazy loaded. This is what PSPDFKit library does if you check the resultant HTML (https://i.imgur.com/7SMZmrg.png).
I have tried overwritting the canvas render using onRenderSuccess and extracting the image from the canvas myself:
Before you start - checklist
Description
I would like to get a new renderer besides
SVG
andCanvas
, as I would like to use plain images as a render mode (which I belive is whatcanvas
is doing under the hood).The final goal is to create a renderer that includes the page as multiple chunks of images (512x512px max) so that it can be lazy loaded. This is what PSPDFKit library does if you check the resultant HTML (https://i.imgur.com/7SMZmrg.png).
I have tried overwritting the canvas render using
onRenderSuccess
and extracting the image from the canvas myself:with a custom CSS for canvas
The result is a bit sketchy:
Proposed solution
Add a
customMainLayerRenderer
prop for Page componentAlternatives
No response
Additional information
No response
The text was updated successfully, but these errors were encountered: