Skip to content

Geolocation API doesn't fit specification #17232

@EJohnF

Description

@EJohnF

RN documentation says:

The Geolocation API extends the web spec: https://developer.mozilla.org/en-US/docs/Web/API/Geolocation

If open that site, we can find

PositionOptions.maximumAge Secure context
Is a positive long value indicating the maximum age in milliseconds of a possible cached position that is acceptable to return. If set to 0, it means that the device cannot use a cached position and must attempt to retrieve the real current position. If set to Infinity the device must return a cached position regardless of its age. Default: 0

So that default value is 0

While in actual RN implementation
android
ios

You can see that default value is INFINITY.

In conclusion: I think need to either edit RN docs and put an additional comment about that difference or change the implementation to fit Mozilla docs.

Thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Ran CommandsOne of our bots successfully processed a command.Resolution: LockedThis issue was locked by the bot.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions