WorkerTileLoader uses obsolete path
Closedopened 4 years ago by uoestermeier · 2 comments
Reference in New Issue
There is no content yet.
Delete Branch '%!s(<nil>)'
Deleting a branch is permanent. It CANNOT be undone. Continue?
The worker in Pixi.deepzoom.loader.WorkerTileLoader uses a WebWorker with an old relative path that no longer works if the iwmlib is used with node_modules:
Should this be changed as follows or is there a better way without assuming that the iwmlib is always used within node_modules?
Doesn't work a relative path to the same directory?
let worker = this.worker = new Worker("./tileloader.js")
Changed the option "preferWorker" to "useWorker" (class DeepZoomImage). If a WebWorker should be used, the "useWorker" option must be given a path relative from the HTML document to the worker, e.g. useWorker: '../tileloader.js' (see https://zzz.buzz/2017/03/14/relative-uris-in-web-development/#the-worker-constructor).