maximum dimensions
Closed this issue · 2 comments
brianteeman commented
Hi, great project.
Maybe I missed something obvious but I couldn't see a way to set the flipbook to use the maximum height and width of the viewport. I could only see a way to se absolute dimensions in pixels.
theproductiveprogrammer commented
Hi @brianteeman
Thanks for the appreciation! ❤️
To set the flipbook to the height and width of the window's client area (the viewport) would look something like:
const opts = {
width: window.innerWidth,
height: window.innerHeight,
}
flipbook(book, 'div-id', opts, (err, viewer) => ...
I hope that helps. Apologies for the late response. Was on holiday.
brianteeman commented
thanks