iTowns / itowns

A Three.js-based framework written in Javascript/WebGL for visualizing 3D geospatial data
http://www.itowns-project.org
Other
1.07k stars 290 forks source link

Typeerror: cannot read properties of undefined (reading from) #2293

Open MiguelG97 opened 3 months ago

MiguelG97 commented 3 months ago

I'm using the npm package and went through many issues but I'm stuck with this one: image

Your Environment

Context

Steps to Reproduce (for bugs)

  1. Install an npm package
  2. Used the following code
import itowns from "itowns";
const view = new itowns.GlobeView(
      viewer.ui.viewerContainer as HTMLDivElement
    );
    const potreeLayer = new itowns.PotreeLayer(
      "ifcpampaenergia",
      {
        source: new itowns.PotreeSource({
          file: "cloud.js",
          url: "assets/potree/ifc-17/",
          crs: view.referenceCrs,
        }),
      }
    );

4. 5.

Expected Behavior

Actual Behavior

Possible Cause/Fix/Solution