web-ifc-three icon indicating copy to clipboard operation
web-ifc-three copied to clipboard

IfcManager uses local IFCWorker.js

Open ThomasvanHoutum opened this issue 2 years ago • 1 comments

I am using the IFCjs with vue example project. In the IfcManager.js function "setupIfcLoader" a path to a local IFCWorker is used:

async setupIfcLoader() {
        let self = this;
        await self.ifcLoader.ifcManager.useWebWorkers(true, '../IFCjs/IFCWorker.js')
        await self.ifcLoader.ifcManager.applyWebIfcConfig({
            COORDINATE_TO_ORIGIN: true,
            USE_FAST_BOOLS: false
        });
        self.setupThreeMeshBVH();
    }

Can that path be changed to the IFCWorker that is in the node module, so the local file can be removed from the project directory?

ThomasvanHoutum avatar Feb 15 '23 12:02 ThomasvanHoutum

That's loaded on runtime. It has to be an accesible URL. The browser will request the file.

fedelaport avatar Mar 02 '23 13:03 fedelaport