[SOLVED] Error at production build step with bundle-visualizer: unknown: Cannot read property 'add' of undefined while minifying

And I have also tried to register pdfjs-dist for recompilation, as suggested here, without success.