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


    微信小程序 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
    }
    
  • 相关阅读:
    radio按钮组和label标签
    div布局
    bootstrap模态框使用
    bootstrap按钮组下拉菜单使用
    Bootstrap下拉菜单和导航栏的使用
    Bootstrap源码解读下拉菜单
    python中django学习2
    windows下配置桌面github
    状态模式--无尽加班何时休
    直接在安装了redis的Linux机器上操作redis数据存储类型--set类型
  • 原文地址:https://www.cnblogs.com/ningzy/p/9113839.html
Copyright © 2020-2023  润新知