I always get this error every time I load the PDF in the PDF viewer for the first time in my browser.
Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'appendChild')
at o.createNotificationPopup (pdf-editor-DzDyRoS7.js:350:119750)
at o.openNotificationPopup (pdf-editor-DzDyRoS7.js:350:120905)
at o.onControlError (pdf-editor-DzDyRoS7.js:350:290027)
at o.createAjaxRequest (pdf-editor-DzDyRoS7.js:350:116919)
at pdf-editor-DzDyRoS7.js:350:107203
The error seems to be coming from this line.
o.prototype.createNotificationPopup = function(e) {
var t = this;
if (!this.isMessageBoxOpen) {
var A = O("div", {
id: this.pdfViewer.element.id + "_notify",
className: "e-pv-notification-popup"
});
!d(this.pdfViewer.pageOrganizer) && this.pdfViewer.pageOrganizer.dialogDivElement ? this.pdfViewer.pageOrganizer.dialogDivElement.appendChild(A) : this.viewerContainer.appendChild(A),
The error is trigged when loading a document to the viewer.
viewer.load('document.pdf', '')
Here is a sample setup of my pdf viewer
https://jsfiddle.net/gilbertdim/Lh0gz7ow/31/