I am developing an application in vue-js and im having issues with the readImageDICOMFileSeries method. I’m currently not using a web-worker and it keeps returning this error. “ImageIO.worker.js:1 Uncaught SyntaxError: Unexpected token <”. Here is the code for my component.
Probably to late, but the problem is that the web-workers are not loaded correctly. In our case, we solved the problems as follow:
You need to place the ImageIOs and WebWorkersfrom here into the public forlder (in our example in /public/itk/ImageIOs and /public/itk/WebWorkers.
import itkreadImageDICOMFileSeries from "itk/readImageDICOMFileSeries";
import itkConfig from "itk/itkConfig";
// this configures ITK library to load the webworkers from
// the corect path (relative to `/public`)
itkConfig.itkModulesPath = "/itk";
Then readImageDICOMFileSeries should work correctly