微信小程序项目配置

原创 2018-11-21 10:30:48 384
摘要:项目配置全局配置都在小程序最外面的App.json文件中进行pages 配置小程序用到的所有页面,放在第一位的默认为首屏显示【pages/index/index】"pages":[ "pages/index/index", "pages/goods/index", "pages/goods/list", "p

项目配置全局配置都在小程序最外面的App.json文件中进行

pages 配置小程序用到的所有页面,放在第一位的默认为首屏显示【pages/index/index】

"pages":[
"pages/index/index",
"pages/goods/index",
"pages/goods/list",
"pages/goods/details",
"pages/shop/list",
"pages/shop/order",
"pages/my/index",
"pages/my/order",
"pages/my/order_details"
]

window 配置小程序最顶端头部的样式,头部显示文字背景色样式等等

"window":{
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#009080",
"navigationBarTitleText": "小程序微商城",
"navigationBarTextStyle": "white",
"backgroundColor": "#fff"
}

tabBar 配置小程序底部导航菜单,用到的小图标,图标下方文字显示的样式等

"tabBar":{
"list" : [
{
"pagePath" : "pages/index/index",
"text" : "首页",
"iconPath" : "img/index.png",
"selectedIconPath": "img/indexs.png"
},
{
"pagePath": "pages/goods/index",
"text": "商品",
"iconPath": "img/goods.png",
"selectedIconPath": "img/goodss.png"
},
{
"pagePath": "pages/shop/list",
"text": "购物车",
"iconPath": "img/shop.png",
"selectedIconPath": "img/shops.png"
},
{
"pagePath": "pages/my/index",
"text": "个人中心",
"iconPath": "img/my.png",
"selectedIconPath": "img/mys.png"
}
],
"color" : "#000",
"selectedColor" : "#bbb"
}


批改老师:韦小宝批改时间:2018-11-21 13:39:25
老师总结:嗯!写的很不错!代码都跟完整!继续加油吧!

发布手记

热门词条