GIScience / Leaflet.Heightgraph

Leaflet plugin to visualize height information and road attributes.
https://giscience.github.io/Leaflet.Heightgraph
MIT License
100 stars 42 forks source link

Error when import in angular project #120

Open mengyu-dev opened 3 years ago

mengyu-dev commented 3 years ago

When imported in an Angular project, it prevents Angular application from starting because of the deprecated dependency d3-collection which redefines some collection classes in the global score, like Map, Set. These old incomplete implementations cause problems.

in the core.js of Angular, it uses Map and Set of the new language specification

// like this:
       this.source = source;
        var records = this._records = new Map();
// like this: 
       var componentDefPendingResolution = new Set();