Add worker to public directory

This commit is contained in:
Kurt Hutten
2020-11-14 20:10:46 +11:00
parent 955f4c9e83
commit 439d5580f3
2 changed files with 2 additions and 2 deletions

View File

@@ -8,7 +8,7 @@
},
"scripts": {
"comment": "Rather crude approach to move ts definitions into the public folder so the browser can grab them later in CascadeMain.js",
"move-ts-defs": "cp ./node_modules/opencascade.js/dist/opencascade.d.ts ./web/public && cp ./node_modules/three/src/Three.d.ts ./web/public && cp ./web/src/cascade/js/StandardLibraryIntellisense.ts ./web/public"
"move-ts-defs": "cp ./node_modules/opencascade.js/dist/opencascade.d.ts ./web/public && cp ./node_modules/three/src/Three.d.ts ./web/public && cp ./web/src/cascade/js/StandardLibraryIntellisense.ts ./web/public && cp ./web/src/cascade/js/CADWorker/CascadeStudioMainWorker.js ./web/public"
},
"devDependencies": {
"@redwoodjs/core": "^0.19.2"

View File

@@ -29,7 +29,7 @@
// Begins loading the CAD Kernel Web Worker
if (window.Worker) {
cascadeStudioWorker = new Worker('/src/cascade/js/CADWorker/CascadeStudioMainWorker.js');
cascadeStudioWorker = new Worker('/CascadeStudioMainWorker.js');
// Ping Pong Messages Back and Forth based on their registration in messageHandlers
// var messageHandlers = {};
cascadeStudioWorker.onmessage = function (e) {