微信小程序 | app.json配置属性

app.json 文件用来对微信小程序进行全局配置,决定页面文件的路径、窗口表现、设置网络超时时间、设置多 tab 等。
widows: 用于设置小程序的状态栏、导航条、标题、窗口背景色。
navigationBarBackgroundColor 导航条背景颜色可用 十六进制颜色代码
navigationBarTextStyle 导航条文字颜色只支持 black / white
navigationBarTitleText 导航条文本内容 String
navigationStyle 导航条样式只支持 default:默认样式 custom:只保留右上角胶囊按钮
tabBar: 用于设置底部tab栏
color tab栏文字颜色 十六进制颜色代码
selectedColor 选中时文字颜色 十六进制颜色代码
backgroundColor tab栏背景颜色 十六进制颜色代码
borderStyle tab栏上边框颜色 black / white
position tab栏位置 bottom / top 若为top则无法显示图标
list 设置tab项最多5项 数组
pagePath 设置页面路径 string
text tab项文字 string
iconPath 设置图标路径 string
selectedIconPath 设置选中后图标路径 string
networkTimeout 设置网络超时时间
request wx.request 的超时时间,单位毫秒。默认60000
connectSocket wx.connectSocket 的超时时间,单位毫秒。默认60000
uploadFile wx.uploadFile 的超时时间,单位毫秒。默认60000
downloadFile wx.downloadFile 的超时时间,单位毫秒。默认60000

猜你喜欢

转载自www.cnblogs.com/WXGC-yang/p/9823148.html
今日推荐