微信小程序app.json配置
找到app.json文件,找到window配置项
1.windows选项下导航栏样式
"navigationBarBackgroundColor":#F6F6F6 // 导航栏的背景颜色
"navigationBarTextStyle":"white" // 导航栏的标题颜色,只支持balck 或者 white
"navigationBarTitleText":"导航栏标题内容" // 导航栏的标题
"navigationStyle":"custom" // 导航栏的样式,只能default 或者 custom, 如果设置为custom,那么就会去掉默认导航栏
2.窗口的颜色。窗口指的是小程序页面上拉或者下拉的背景颜色,可以在真机上调试。
"backgroundColor":"#000" // app.json配置文件中的所有颜色值都只能写色标,不能使用颜色单词,除navigationBarTextStyle的这个选项外。
设置上滑时和下拉时的背景颜色[只在ios上上生效]:
"backgroundColorTop":"#333",
"backgroundColorBottom":"#999"
在真机上查看效果:
点击编辑器上的预览按钮,扫描生成的二维码,就可以在手机上打开小程序。
3.开启下拉刷新,在电脑也能下拉:
"enablePullDownRefresh":true
也可以在其他页面的json文件中使用"navigationBarTitleText",配置页面的标题。
微信小程序app.json配置的更多相关文章
- 微信小程序 app.json 配置
我们使用app.json文件来对微信小程序进行全局配置,决定页面文件的路径.窗口表现.设置网络超时时间.设置多 tab 等. 以下是一个包含了所有配置选项的简单配置app.json : { " ...
- 微信小程序 | app.json配置属性
app.json 文件用来对微信小程序进行全局配置,决定页面文件的路径.窗口表现.设置网络超时时间.设置多 tab 等. widows: 用于设置小程序的状态栏.导航条.标题.窗口背景色. navig ...
- 微信小程序 - app.json配置解析
{ "pages": [ "pages/index/index", "pages/logs/logs", "pages/login ...
- 微信小程序app.json文件常用全局配置
小程序根目录下的 app.json 文件用来对微信小程序进行全局配置,决定页面文件的路径.窗口表现.设置网络超时时间.设置多 tab 等. JOSN文件不允许注释,下面为了学习加上注释,粘贴需要的片段 ...
- 微信小程序 app.json文件配置
https://developers.weixin.qq.com/miniprogram/dev/index.html 起步 https://developers.weixin.qq.com/min ...
- 微信小程序 --- app.json文件
app.json文件用于配置项目:用于对小程序进行全局设置: pages:定义小程序的路由.(凡是不在这个配置里面的东西,都无法打开) (特别注意:结尾不能有 逗号 否则会出错) window:定义小 ...
- 微信小程序---app.json中设置背景色不生效解决办法
按照官方文档的说明,backgroundColor应该可以设置窗口的背景色. "window":{ "backgroundTextStyle":"li ...
- 微信小程序:全局配置app.json
微信小程序:全局配置app.json 一.全局配置app.json app.json文件用来对微信小程序进行全局配置,决定页面文件的路径.窗口表现.设置网络超时时间.设置多 tab 等. 以下是一个包 ...
- 微信小程序:页面配置 page.json
微信小程序:页面配置 page.json 一.页面配置 page.json 如果整个小程序的风格是蓝色调,那么可以在 app.json 里边声明顶部颜色是蓝色即可. 实际情况可能不是这样,可能你小程序 ...
随机推荐
- use crunch compression
Crunch is a lossy compression format on top of DXTR texture compression. Textures will be converted ...
- Leading and Trailing (数论)
Leading and Trailing https://vjudge.net/contest/288520#problem/E You are given two integers: n and k ...
- Win7系统不能记忆窗口大小与位置解决方法
似在某此系统优化后,无意发现系统在注销或重启后,打开资源管理器,它以默认大小及位置显示. 对于习惯自定义操作来说,甚为不便,遍找方法未有奏效者,但总萦绕心头,时时记起. 今日再找问题解决方法,难兄难弟 ...
- swift - iOS10之后的加速器
import UIKit //1.加速器框架 import CoreMotion class ViewController: UIViewController { //1.创建运动管理者 必须设置为 ...
- swift - layer - 渐变色 - CAGradientLayer
1.创建 渐变色 /// 渐变色:默认从上到下 private var gradientLayer: CAGradientLayer = { let g = CAGradientLayer() g.c ...
- [leetcode]658. Find K Closest Elements绝对距离最近的K个元素
Given a sorted array, two integers k and x, find the k closest elements to x in the array. The resul ...
- JFinal Web开发学习(三)前后台路由设计
效果图: 一.写控制器 1.在controller包中新建AdminController后台控制器,继承Controller,实现一个index方法,作为的处理方法. /admin 后面,这个控制器中 ...
- vue路由权限之访问权限(meta控制是否有访问权限)
首先登录那权限表 router.beforeEach((to, from, next) => { if(to.path === '/login') { next(); }else{ if(!st ...
- laravel框架一次请求的生命周期
第一件事所有的请求都会被web服务器(Apache/Nginx)导向public/index.php文件.index.php文件载入Composer生成的自动加载设置,然后从bootstrap/app ...
- linux下svn导入新目录到svn服务器特定地址
svn import transplant-apps/ svn://xx.xx.xx.90/ -m "changelog:add transplant-apps to 90-svn" ...