My problem is: how to modify an array of objects directly coming from a request ?
A little bit of context:
When a user requests a product to be delivered, I want to show all the relay points available, and to sort those by proximity.
I have access to latitude and longitude of both the client and the relay points. But to sort by proximity, I need to perform a heavy calculation due to the Earth being spheric (sorry Flat-Earthers ).
- Is it even possible in Bubble ? Didn’t see many options about this kind of calculus.
- How to do the calculation, add it as a property to the object, and then sort ? (just as map function would do in a programmatic language).
Thanks in advance for your answers !