function initViewer(browserApi) {
  // PDFViewer will handle any messages after it is created.
  window.removeEventListener('message', handleScriptingMessage, false);
  viewer = new PDFViewer(browserApi);
  while (pendingMessages.length > 0)
    viewer.handleScriptingMessage(pendingMessages.shift());
}
/**
 * Initialize the global PDFViewer and pass any outstanding messages to it.
 *
 * @param {Object} browserApi An object providing an API to the browser.
 */
Initialize the global PDFViewer and pass any outstanding messages to it.
@param {Object} browserApi An object providing an API to the browser.
Initialize the global PDFViewer and pass any outstanding messages to it . @param { Object } browserApi An object providing an API to the browser .
function initViewer(browserApi) {
  window.removeEventListener('message', handleScriptingMessage, false);
  viewer = new PDFViewer(browserApi);
  while (pendingMessages.length > 0)
    viewer.handleScriptingMessage(pendingMessages.shift());
}
function initViewer ( browserApi ) { window . removeEventListener ( 'message' , handleScriptingMessage , false ) ; viewer = new PDFViewer ( browserApi ) ; while ( pendingMessages . length > 0 ) viewer . handleScriptingMessage ( pendingMessages . shift ( ) ) ; }
Initialize the global PDFViewer and pass any outstanding messages to it.
Initialize the global PDFViewer and pass any outstanding messages to it .
// PDFViewer will handle any messages after it is created.