How to import a node module inside an angular web worker?
问题 I try to import a node module inside an Angular 8 web worker, but get an compile error 'Cannot find module'. Anyone know how to solve this? I created a new worker inside my electron project with ng generate web-worker app , like described in the above mentioned ng documentation. All works fine until i add some import like path or fs-extra e.g.: /// <reference lib="webworker" /> import * as path from 'path'; addEventListener('message', ({ data }) => { console.log(path.resolve('/')) const