0
Follow
0
View

uniapp uses map components for white screen length and marker points too much

ZOOOOM 注册会员
2023-02-27 20:16

This answer quotes ChatGPT

In view of the long white screen time and too many marker points when map components are used in uniapp, the following optimization methods can be tried:

1. Load Marker points asynchronously: If there are a lot of data about Marker points, only the Marker points within the current field of vision can be loaded asynchronously, and then new Marker points can be loaded asynchronously when the map moves, so as to reduce the initial loading time and occupy memory.

2. Use marker point aggregation: When there are too many Marker points, the aggregation technology can be considered to combine adjacent Marker points into one Marker point, so as to reduce the burden of rendering.

3. Use pictures or thumbnails to replace marker points: If the information of Marker points is relatively simple, you can use pictures or thumbnails to replace marker points to reduce the burden of rendering.

4. Use web worker: The web worker can be used to calculate and render Marker points in another thread, so as to reduce the burden of the main thread and improve rendering efficiency.

5. Cache the position of Marker points: If the position information of Marker points does not need to be updated in real time, it can be cached locally to avoid repeated network requests and reduce rendering time.

6. Optimize the request of map data: It is possible to optimize the request mode of Marker point data, such as the paging loading mode, to reduce the pressure of returning a large amount of data at one time, and set the request timeout time, etc.

About the Author

Question Info

Publish Time
2023-02-27 20:16
Update Time
2023-02-27 20:16

Related Question

react hooks map渲染显示问题

使用react-native-maps和Expo加载web地图组件时出错

uniapp云开发的云对象不能用tyepscript定义类型吗?

如何在舵图kubernetes中为不同的服务传递不同的confimap映射值?

uniapp中ArrayBuffer和json格式互转

仅当属性与map函数存在时使用过滤器

R tmap: Adjust line height in two-line legend title

uniapp 微信小程序getfuzzylocation获取不到定位?

arcmap进行缓冲区分析时报错

如何使用imap_tools将文件从传入的电子邮件保存到AWS S3桶