Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PolygonUtil.decode is broken on web #27

Closed
timbotimbo opened this issue Sep 18, 2023 · 1 comment
Closed

PolygonUtil.decode is broken on web #27

timbotimbo opened this issue Sep 18, 2023 · 1 comment

Comments

@timbotimbo
Copy link

A decoded polyline that works fine on iOS and Android, is fully broken on web.
It will turn into one or more straight lines.

This is an Android emulator (left) next to Chrome (right).
polyline

I've use this polyline in the screenshot above.

u|ywHi_za@cM{U}PcIaB~@a@Vi@Fs@Pw@x@o@rAsD_HGcCy@l@oBpBMNi@f@URoAnASVqBzAuAd@eANgCIa@?k@DHXFp@aAn@eA]o@j@qAbBqAvB}A~Ci@`BQv@_@z@eB`C_@v@c@rAy@vAoBvCqCvD{@|@WNw@HSh@_@z@uAr@e@b@i@sAGq@Eu@CmBqAy@}@u@YMwAyAc@cAeAoDjAuAbFuIfBaCeBqFOi@cA}I?gADw@RcBLkBJcE?wCJQY_EH}DuA}HoBuGgDiEi@m@][q@a@m@Qm@IiB?UHUk@mBeIOeAAkABs@r@iEtB}RLcBQIo@i@oAeBg@}@UUoBuC_@[u@[}B_@qCmAq@QU[CL[JuBGa@I{@Gk@d@MRWJa@MK_AN_@?g@IkAQa@GR}HhIq@Ri@Ja@@mAM_A]aAm@iA[KFmAyAgAyBEa@Eg@JaAZi@xAqB~AmCrAuC|BoEFQdBuDNWXq@v@wA\\a@_@kA_@yB_@wAm@sAXeAIuLMyGMiE^Ef@_@t@y@pCgCnBoCnAM|@KnBgBPGDx@Ob@\\tEVl@~M}Cp@@LLvAShAa@|@u@d@Yn@Ux@GZ@C{BQwBUgCaAoIWwD?_@H@pIo@d@G~@?bBz@tAxAfAzCTj@fBxGvArFvEcCjAjHNZ`@a@rFiCnCcAj@GrECJv@zBxEt@bA~@p@`Bt@z@b@h@`@Z`@xArBT?rD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uAzIa@zA}ArFa@vA[t@a@j@{EhFBx@@vFHb@BXDp@Cz@MjDA|CF~@dArQOfAMdAqErc@wK_FmLyFm@Uo@CeCA{JmIyEoDqBkDsBw@uBm@CjBqAzOO~ASpAYbA_DvHMj@YnBUjEQvA_@nAs@zBWU}BoBq@kBgA{E]g@aAHg@AiGmAiABoBd@cDTiA?aD]kAHqD|@eB`@sAJ@~FDvBLnBPxAVdAh@p@V^N^r@pCl@z@|@n@Xb@~@vBjC~DVt@sFnG_@Pe@Fa@EsD_@cCQUe@_@?Un@u@JuBT{BJqCPgCOwBBoBZcAA{@QgAc@m@Sw@BmBH}Bo@aCc@oCUiACcAUi@_@]GWqB]}BUeAWq@c@_@uB{BW@In@EtAKbAm@@_Ao@eGwIv@kDKsDoDsRsAgBuJp@gF`AkBz@

This exact issue was reported before, but using flutter_polyline_points instead. flutter/flutter#86349

The issue is related to how bitwise operations are compiled to javascript. The solution in the other plugin was to use BigInt.
Dammyololade/flutter_polyline_points#40 (comment)

@kb0
Copy link
Owner

kb0 commented Sep 18, 2023

fix in 3.0.0

@kb0 kb0 closed this as completed Sep 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants