You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Sep 9, 2021. It is now read-only.
const ctx: Worker = self as any;
// Post data to parent thread
ctx.postMessage({ foo: "foo" });
// Respond to message from parent thread
ctx.addEventListener("message", (event) => console.log(event));
It compiles, but the file is outputted under f88912265db2b5d37cdb.worker.js filename, and the path doesn't include /scripts/ part.
I've tried to change import statement to include options as params as follows (based on #117 ) App.ts:
Above import throws following error: Cannot find module 'worker-loader?name=scripts/worker.js!./Worker'.but after all it compiles properly and javascript works, hence I'm not allowed to leave error message in console.
I'd like to make options section working with Typescript OR get rid of "Cannot ind module" ERROR.
The text was updated successfully, but these errors were encountered:
Melmoth-the-Wanderer
changed the title
Options doesn't work with Typescript and Webpack 3
[FIXED] Options (name/publicPath) doesn't work with Typescript and Webpack 3 config file
Feb 6, 2018
I'm Using Webpack 3.10.0, Typescript 2.6.2, worker-loader 1.1.0.
webpack.config
App.ts:
Worker.ts:
It compiles, but the file is outputted under
f88912265db2b5d37cdb.worker.js
filename, and the path doesn't include/scripts/
part.I've tried to change import statement to include options as params as follows (based on #117 )
App.ts:
Above import throws following error:
Cannot find module 'worker-loader?name=scripts/worker.js!./Worker'.
but after all it compiles properly and javascript works, hence I'm not allowed to leave error message in console.I'd like to make options section working with Typescript OR get rid of "Cannot ind module" ERROR.
The text was updated successfully, but these errors were encountered: