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
Testing my app with PhantomJS worked well till updating Turf from v4.6 to v5.1.6 ; it now fails with ReferenceError: Can't find variable: Map for a given line in turf.min.js (custom build through turf-builder).
It seems to be kind of a known issue when Map is called inside PhantomJS as it doesn't support ES6 features.
found that the source file in v5.1 includes new Map();:
function HashMap () {
MapInterface.call(this);
this.map_ = new Map();
}
@ath0mas I'd recommend using the specific modules that you need instead of the global Turf.
We won't be publishing another global bundle until v6.x, so even if this change is patched it "should" no longer use jsts (which uses this Map polyfill).
Testing my app with PhantomJS worked well till updating Turf from v4.6 to v5.1.6 ; it now fails with
ReferenceError: Can't find variable: Map
for a given line in turf.min.js (custom build through turf-builder).It seems to be kind of a known issue when
Map
is called inside PhantomJS as it doesn't support ES6 features.found that the source file in v5.1 includes
new Map();
:and that in v5.0 it was polyfilled:
as a result, source is not pure ES5
know why this change?
The text was updated successfully, but these errors were encountered: