Version 8.7.0
I want to have all pages to be visible, one under the other.
I tried it with UI.setLayoutMode(UI.LayoutMode.Continuous) but it doesn’t work.
The pdf container has an appropiate size for all pages.
Pls check attached simple example. What I am doing wrong ?
<html>
<head>
<title>feature test</title>
<script>
function init() {
WebViewer({
path: './lib', // path to the PDF.js Express'lib' folder on your server
licenseKey: 'erYOL5fTH6Qt7nvCTnmQ',
initialDoc: './test.pdf'
}, document.getElementById('pdfcont')
).then(instance => {
const {Core, UI} = instance;
UI.setFitMode(UI.FitMode.FitPage);
UI.setLayoutMode(UI.LayoutMode.Continuous);
})
}
</script>
</head>
<body onload="init()">
<div id="pdfcont" style="width:600px;height:1500px;background-color: aliceblue"></div>
<script src="lib/webviewer.min.js"></script>
</body>
</html>