Coordinates.latitude

Baseline Widely available

This feature is well established and works across many devices and browser versions. It’s been available across browsers since July 2015.

安全上下文: 此项功能仅在一些支持的浏览器安全上下文(HTTPS)中可用。

Coordinates.latitude 只读属性,十进制双精度浮点数来表示纬度坐标

语法

lat = coordinates.latitude

规范

Specification
Geolocation
# latitude-longitude-and-accuracy-attributes

浏览器兼容性

BCD tables only load in the browser

参见