distance function Null safety

num distance(
  1. Point from,
  2. Point to,
  3. [Unit unit = Unit.kilometers]
)

Implementation

num distance(Point from, Point to, [Unit unit = Unit.kilometers]) =>
    distanceRaw(from.coordinates, to.coordinates, unit);