AirQualityMeterElement class
google.maps.airQuality
. AirQualityMeterElement
class
extends HTMLElement
implements AirQualityMeterElementOptions
Displays air quality information for a given location.
<gmp-air-quality-meter location=" lat,lng "> </gmp-air-quality-meter>
const { AirQualityMeterElement } = await google . maps . importLibrary ( "airQuality" );
Constructor
AirQualityMeterElement([options])
Parameters:
-
options:AirQualityMeterElementOptions optional
Properties |
|
|---|---|
location
|
Type:
LatLngLiteral
| LatLng
| LatLngAltitudeLiteral
| LatLngAltitude
optional
Default:
null
The location to render the air quality meter for. Normalizes to a
LatLngAltitude
. HTML attribute:
location="lat,lng"
|
requestedLanguage
|
Type:
string optional
Default:
null
An override for the language to request from the Air Quality API
. See the list of supported languages
.
|
Methods |
|
|---|---|
Inherited:
addEventListener
, removeEventListener
|
Events |
|
|---|---|
gmp-error
|
function()
Arguments: None
Event fired when the
AirQualityMeterElement
has an error in loading. |
gmp-load
|
function()
Arguments: None
Event fired when the
AirQualityMeterElement
has finished loading. |
AirQualityMeterElementOptions interface
google.maps.airQuality
. AirQualityMeterElementOptions
interface
AirQualityMeterElement options.
Properties |
|
|---|---|
location
optional
|
Type:
LatLngLiteral
| LatLng
| LatLngAltitudeLiteral
| LatLngAltitude
optional
|
requestedLanguage
optional
|
Type:
string optional
|

