Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Page width is Nan #1899

Open
3 of 4 tasks
yumikim381 opened this issue Oct 14, 2024 · 1 comment
Open
3 of 4 tasks

Page width is Nan #1899

yumikim381 opened this issue Oct 14, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@yumikim381
Copy link

Before you start - checklist

  • I followed instructions in documentation written for my React-PDF version
  • I have checked if this bug is not already reported
  • I have checked if an issue is not listed in Known issues
  • If I have a problem with PDF rendering, I checked if my PDF renders properly in PDF.js demo

Description

Following code gives nan for page.width

Steps to reproduce

Following code gives nan for page.width
const page = await document.getPage(1); setPageWidth(page.width); setPageHeight(page.height); console.log("initial setting of the page heights and widths") console.log("pageheight", pageHeight) console.log("pagewidth", pageWidth)

Expected behavior

some number

Actual behavior

initial setting of the page heights and widths
pdfviewer2.tsx:76 pageheight 1418.0625
pdfviewer2.tsx:77 pagewidth NaN

Additional information

No response

Environment

  • Browser (if applicable):
  • React-PDF version:
  • React version:
  • Bundler name and version (if applicable):
@yumikim381 yumikim381 added the bug Something isn't working label Oct 14, 2024
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants
@yumikim381 and others