更新记录
1.0.1(2024-08-30)
下载此版本
更新
1.0.0(2024-08-30)
下载此版本
组件初始化
平台兼容性
uni-app
Vue2 |
Vue3 |
Chrome |
Safari |
app-vue |
app-nvue |
Android |
iOS |
鸿蒙 |
√ |
- |
- |
- |
√ |
√ |
- |
- |
- |
微信小程序 |
支付宝小程序 |
抖音小程序 |
百度小程序 |
快手小程序 |
京东小程序 |
鸿蒙元服务 |
QQ小程序 |
飞书小程序 |
快应用-华为 |
快应用-联盟 |
- |
- |
- |
- |
- |
- |
- |
- |
- |
- |
- |
其他
ly-weather
基本用法
1.在需要的页面引入该插件
import lyWeather from '@/components/ly-weather/ly-weather.vue';
2.在需要的页面使用
<ly-weather ref="lyWeather" :nowData="nowData" :data="data"></ly-weather>
3.在当需要引入的页面定义天气数据
nowData:{
temperature:30,
city:'兰州',
weather: "晴",
wind:'西南风',
level:'2级',
humidity:'20%',
airQuality:34
}
data: [{
week: "周二",
label: "8/11",
weather: "雪",
weatherIcon: require("../../static/15.png"),
max: 34,
min: 27,
wind: "西南风",
air: "良"
}, {
week: "周三",
label: "8/12",
weather: "雪",
weatherIcon: require("../../static/15.png"),
max: 34,
min: 27,
wind: "西南风",
air: "良"
}, {
week: "周四",
label: "8/13",
weather: "晴",
weatherIcon: require("../../static/16.png"),
max: 36,
min: 27,
wind: "西南风",
air: "良"
}, {
week: "周五",
label: "8/14",
weather: "晴",
weatherIcon: require("../../static/16.png"),
max: 35,
min: 26,
wind: "西南风",
air: "良"
}]