1 {
2 "pages": [
3 "pages/index/index",
4 "pages/logs/logs",
5 "pages/login/login"
6 ],
7 "window": {
8 /**
9 * 以下是页面顶部导航栏设置
10 **/
11 "navigationBarBackgroundColor": "#ffffff", // 导航栏背景颜色,默认值:#000000
12 "navigationBarTextStyle": "black", // 导航栏标题颜色,默认值white
13 "navigationBarTitleText": "wechat", // 导航栏标题文字内容
14 "navigationStyle": "default", // 导航样式,默认值default。 custom 自定义导航栏,只保留右上角胶囊按钮
15 /**
16 * 以下是下拉刷新或上拉触底设置
17 **/
18 "backgroundColor": "#eee", // 窗口的背景色
19 "backgroundTextStyle": "light", // 下拉 loading 的样式,默认值dark(暗)
20 "backgroundColorTop": "#aaa", // 顶部窗口的背景色,仅 iOS 支持
21 "backgroundColorBottom": "#aaa", // 底部窗口的背景色,仅 iOS 支持
22 "enablePullDownRefresh": true, // 是否全局开启下拉刷新,值 true | false
23 "onReachBottomDistance": 50 // 页面上拉触底事件触发时距页面底部距离,单位为px,默认值 50
24 },
25 "tabBar": {
26 "color": "#000", // 【必需】 tab 上的文字默认颜色
27 "selectedColor": "#56abe4", // 【必需】 tab 上的文字选中时的颜色
28 "backgroundColor": "#fff", // 【必需】 tab 的背景色
29 "borderStyle": "white", // tabbar上边框的颜色, 默认值:black
30 "position": "bottom", // tabBar的位置,仅支持 bottom / top
31 /**
32 *【必需】 tab 的列表,最少2个、最多5个 tab
33 **/
34 "list": [
35 {
36 "pagePath": "pages/index/index", // 【必需】 打开的页面路径,必须在 pages 中先定义
37 "text": "首页" // 【必需】 tab 上按钮文字,比如首页
38 "iconPath": "img/indexIcon", // 图片路径,icon 大小限制为40kb,建议尺寸为 81px * 81px,不支持网络图片。 当 postion 为 top 时,不显示 icon。
39 "selectedIconPath": "img/indexIcon_on // 选中时的图片路径,icon 大小限制为40kb,建议尺寸为 81px * 81px,不支持网络图片。当 postion 为 top 时,不显示 icon。
40 },
41 {
42 "pagePath": "pages/logs/logs",
43 "text": "日志"
44 },
45 {
46 "pagePath": "pages/login/login",
47 "text": "登录"
48 }
49 ]
50 },
51 /**
52 * networkTimeout 各类网络请求的超时时间,单位均为毫秒。
53 **/
54 "networkTimeout": {
55 "request": 30000, // wx.request 的超时时间。默认值 60000
56 "connectSocket": 3000, // wx.connectSocket 的超时时间。默认值 60000
57 "uploadFile": 30000, // wx.uploadFile 的超时时间。默认值 60000
58 "downloadFile": 30000 // wx.downloadFile 的超时时间。默认值 60000
59 },
60 "debug": true, //debug 是否开启调试模式,默认关闭(false)
61 "resizable": true, // 值true时使小程序支持 iPad 屏幕旋转
62 "functionalPages": true, //functionalPages 是否启用插件功能页,默认关闭(false)
63 /**
64 * usingComponents 定义全局可以使用的自定义组件(所有页面可用)
65 **/
66 "usingComponents": {
67 "component-tag-name": "component-path" // 格式:组件标签名称 : 自定义组件路径
68 // 可定义多个自定义组件
69 }
70 }