前言
- 基础库 2.12.0
- 开发者工具 1.03.2008270
自定义导航栏
navigationStyle
可用的值为:default
默认样式、custom
自定义导航栏(只保留右上角胶囊按钮)。自微信客户端 7.0.0(基础库 2.5.2)开始支持。
在哪里定义 navigationStyle
每一个小程序页面也可以使用 .json
文件来对本页面的窗口表现进行配置。页面中配置项在当前页面会覆盖 app.json
的 window
中相同的配置项。
示例:
{
"navigationStyle": "custom"
}
运行效果(下图红框中即是运行效果):
参考
https://developers.weixin.qq.com/miniprogram/dev/reference/configuration/page.html
https://developers.weixin.qq.com/miniprogram/dev/extended/weui/navigation.html