manuels / texlive.js

Compiling LaTeX (TeX live) in your browser
http://manuels.github.com/texlive.js/
GNU General Public License v2.0
1.25k stars 140 forks source link

pdftex.js and pdftex-worker.js must be placed in root #27

Open xylo04 opened 9 years ago

xylo04 commented 9 years ago

Attempting to use texlive.js as a library without modification and also placing it in a vendor folder are currently not possible, because this line in pdftex.js:

var worker = new Worker("pdftex-worker.js");

seems to be relative to root. If possible, I'd like to see if that can be made relative to the calling script. As an alternative, perhaps the content of pdftex-worker.js can be inlined in pdftex.js.

xylo04 commented 9 years ago

Based on this line in index.html, it looks like the intent at one time was to make the PDFTeX constructor take the worker path as an optional parameter. I'll go that direction.