Browse Source

Update docs on the workerSrc setting.

Brendan Dahl 12 years ago
parent
commit
7563a9dfa0
  1. 3
      examples/helloworld/index.html
  2. 4
      src/display/api.js

3
examples/helloworld/index.html

@ -16,7 +16,8 @@
<script type="text/javascript"> <script type="text/javascript">
// Specify the main script used to create a new PDF.JS web worker. // Specify the main script used to create a new PDF.JS web worker.
// In production, change this to point to the combined `pdf.js` file. // In production, leave this undefined or change it to point to the
// combined `pdf.worker.js` file.
PDFJS.workerSrc = '../../src/worker_loader.js'; PDFJS.workerSrc = '../../src/worker_loader.js';
</script> </script>
<script type="text/javascript" src="hello.js"></script> <script type="text/javascript" src="hello.js"></script>

4
src/display/api.js

@ -56,7 +56,9 @@ PDFJS.disableWorker = PDFJS.disableWorker === undefined ?
false : PDFJS.disableWorker; false : PDFJS.disableWorker;
/** /**
* Path and filename of the worker file. Required when the worker is enabled. * Path and filename of the worker file. Required when the worker is enabled in
* development mode. If unspecified in the production build, the worker will be
* loaded based on the location of the pdf.js file.
* @var {String} * @var {String}
*/ */
PDFJS.workerSrc = PDFJS.workerSrc === undefined ? null : PDFJS.workerSrc; PDFJS.workerSrc = PDFJS.workerSrc === undefined ? null : PDFJS.workerSrc;

Loading…
Cancel
Save