Select to view content in your preferred language

Cannot upgrade to Esri 4.34 due to incompatible big integer notation in @arcgis\core\core\mathUtils.js

37
0
4 hours ago
JonathanTiu
Occasional Contributor

I filed this support ticket: https://my.esri.com/#/support/cases/tech-cases?caseNumber=04056221

Basically the problem we ran into is very simple.  our codebase is still stuck on es2017 and cannot upgrade to es2020 anytime soon due to complexity and consumers using us. 

In  Esri 4.32, in @ArcGIS\core\core\mathUtils.js

there is a piece of code that says:
const w=BigInt(1000000),y=B(1);function B(t)con

BigInt notation is supported in es2017 so no problem.

When we tried to upgrade to 4.34, we saw that the above code has been changed to:
const w=1000000n,y=B(1);function B(t)con

The literal 'n' after the number indicates big integer etc. This notation is NOT supported in es2017 but supported in es2020 is what i understand.

Can ESRI change their code references to keep using BigInt() instead of the literal 'n' notation? Was there a reason for this change?

They are equivalent AFAIK.
This would be an easy change on your part and allow consumers still on es2017 to keep working.

Right now we are blocked on upgrading to 4.34 and to 5 next year in the future.

0 Kudos
0 Replies