uni-app 使用pages.json原生tabbar时 tabbar下方留有空隙 无论manifest安全区设置如何
uni-app 使用pages.json原生tabbar时 tabbar下方留有空隙 无论manifest安全区设置如何
1 回复
更多关于uni-app 使用pages.json原生tabbar时 tabbar下方留有空隙 无论manifest安全区设置如何的实战教程也可以访问 https://www.itying.com/category-93-b0.html
在uni-app中使用原生tabbar时,底部出现空隙通常与安全区适配有关。以下解决方案可尝试:
- 在pages.json的tabBar配置中添加:
"tabBar": {
"style": {
"paddingBottom": "0"
}
}
- 检查manifest.json中的安全区配置:
"safearea": {
"bottom": {
"offset": "none"
}
}
- 如果使用自定义tabbar,确保样式设置正确:
.tabbar {
padding-bottom: 0;
margin-bottom: 0;
}
- 对于iOS设备,可尝试添加viewport-fit=cover:
<meta name="viewport" content="viewport-fit=cover">

