小程序系列--如何配置页面属性

简介

每个小程序页面也可使用 .json 文件来对本页面的窗口表现进行配置。页面中配置项在当前页面会覆盖 app.json 的 window 中相同的配置项。页面配置中只能设置 app.json 中 window 对应的配置项,以决定本页面的窗口表现,因此无需写 window 这个属性。
json

属性

文件内容为一个 JSON 对象,有如下属性:小程序

配置示例

{
    "navigationBarBackgroundColor": "#FF4949",
    "navigationBarTextStyle": "white",
    "navigationBarTitleText": "微信页面配置demo",
    "backgroundColor": "#13CE66",
    "backgroundTextStyle": "light",
    "enablePullDownRefresh": true,
    "backgroundColorTop":"#99A9BF",
    "onReachBottomDistance":20,
    "usingComponents": {}
}

image.png

相关文章
相关标签/搜索