Get the App
SLTechnology News&Howtos  ›  Development  › 

What are the basic attributes of WeChat Mini Programs Map map development?

Shulou Source: shulou.com Published: 2022-06-01 06:02:10 10月03日 Update

This article mainly explains "what are the basic attributes of WeChat Mini Programs Map map development", interested friends may wish to have a look. The method introduced in this paper is simple, fast and practical. Next, let the editor take you to learn what are the basic attributes of WeChat Mini Programs Map map development.

Map

Attribute name type default value indicates longitudeNumber center longitude latitudeNumber center latitude scaleNumber1 scale level markersArray marked point coversArray overlay

Marked point

Marked points are used to display the location of markers on the map, and icons and styles cannot be customized.

Attribute description type required remarks latitude latitude Number is a floating point number, range-90 ~ 90longitude longitude Number is a floating point number, range-180 ~ 180name label dot name String is desc dimension point detailed description String No

Covering material

The overlay is used to display custom icons on the map, customizable icons and styles

Attribute description type required remarks latitude latitude Number is a floating point number, range-90 ~ 90longitude longitude Number is a floating point number, range-180 ~ 180iconPath display icon String is the image path under the project directory, support relative path writing rotate rotation angle Number rotation angle clockwise, range 0 ~ 360. default is 0.

The longitude and latitude of the map component is required. If you do not fill in the longitude and latitude, the default value is the longitude and latitude of Beijing.

The marked point markers can only be set during initialization and does not support dynamic updates.

Example:

/ map.jsPage ({data: {markers: [{latitude: 23.099994, longitude: 113.324520, name: 'T.I.T Creative Park', desc: 'where I am'}], covers: [{latitude: 23.099794, longitude: 113.324520, icaonPath:'.. / images/car.png', rotate: 10}, {latitude: 23.099298, longitude: 113.324129 IconPath:'.. / images/car.png', rotate: 90}]}}) so far I believe that everyone has a deeper understanding of "what are the basic attributes of WeChat Mini Programs Map map development". You might as well do it in practice. Here is the website, more related content can enter the relevant channels to inquire, follow us, continue to learn!

Tags: Maps attributes marks ranges icons points programs development type latitude longitude longitude coverage location content comments styles angles paths Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Huawei MySQL Shulou Technology Shulou Tech Info OPPO Reno