I have tried to implement but got error.
var tmppath = URL.createObjectURL(document.getElementById('flupd').files[0]);
PDFJS.workerSrc = "js/test1/pdf.worker.js";
PDFJS.getDocument(tmppath).then(function (pdf) {
pdf.getData().then(function (arrayBuffer) {
var pdfraw = String.fromCharCode.apply(null, arrayBuffer); //Error: Uncaught (in promise) RangeError: Maximum call stack size exceeded
});
});