微信小程序> 微信小程序app.json详细介绍

微信小程序app.json详细介绍

浏览量:748 时间: 来源:NingZheYuan

微信小程序 app.json 详细介绍

{    // 写各个页面的路径 (新增页面或者减少页面都要对其进行修改)    "pages": [        "pages/index/index",        "pages/logs/index"    ],    // 用于设置小程序状态栏 导航条 标题 窗口背景色 (也可以在单个页面中配置 [page.json])    "window": {        "navigationBarBackgroundColor": "HexColor",                 // 导航栏背景色        "navigationBarTextStyle": "HexColor",                       // 导航栏标题颜色        "navigationBarTitleText": "String",                         // 导航栏标题文字内容        "navigationStyle": "default",                               // 导航栏样式 (default/custom)custom 模式可自定义导航栏,只保留右上角胶囊状的按钮        "backgroundColor": "HexColor",                              // 窗口的背景色        "backgroundTextStyle": "dark"                               // 下拉loading样式(dark/light)        "backgroundColorTop": "HexColor",                           // 顶部窗口的背景色(仅支持ios)        "backgroundColorBottom": "HexColor",                        // 底部窗口的背景色        "enablePullDownRefresh":"Boolean"                           // 是否开启下拉刷新        "onReachBottomDistance": "Number"                           // 页面上拉触底事件触发时距页面底部距离,单位为px    },    // 配置项指定 tab 栏的表现,以及 tab 切换时显示的对应页面。    "tabBar": {        "color": "HexColor",                                        // tab文字的默认颜色        "selectedColor": "HexColor"                                 // tab文字选中时的颜色        "backgroundColor": "HexColor"                               // tab的背景颜色        "borderStyle": "String",                                    // tabBar上边框的颜色 仅支持 black/white        "position": "String",                                       // tabBar 所在的位置 ( bottom、top)        "list": [                                                   // 最少2个、最多5个 tab            {                "pagePath": "pages/index/index",                    // 页面路径 (必须在 pages 中先定义)                "text": "首页",                                     // tab 上按钮文字                "iconPath": "String",                               // 图片路径     icon 大小限制为40kb,建议尺寸为 81px * 81px,当 postion 为 top 时,此参数无效,不支持网络图片                "selectedIconPath": "String"                        // 选中时的图片路径  icon 大小限制为40kb,建议尺寸为 81px * 81px,当 postion 为 top 时,此参数无效,不支持网络图片            }        ]    },    // 可以设置各种网络请求的超时时间。    "networkTimeout": {        "request": 10000,                                           // wx.request的超时时间,单位毫秒,默认为:60000        "connectSocket":10000,                                      // wx.connectSocket的超时时间,单位毫秒,默认为:60000        "uploadFile":10000,                                         // wx.uploadFile的超时时间,单位毫秒,默认为:60000        "downloadFile": 10000,                                      // wx.downloadFile的超时时间,单位毫秒,默认为:60000    },    // 开发者工具中开启 debug 模式    "debug": true}

版权声明

即速应用倡导尊重与保护知识产权。如发现本站文章存在版权问题,烦请提供版权疑问、身份证明、版权证明、联系方式等发邮件至197452366@qq.com ,我们将及时处理。本站文章仅作分享交流用途,作者观点不等同于即速应用观点。用户与作者的任何交易与本站无关,请知悉。

产品经理

手机 : 13312967497

擅长 : 小程序流量变现

扫码领取礼包

热门模板

  • 头条
  • 搜狐
  • 微博
  • 百家
  • 一点资讯
  • 知乎