当前位置:网站首页>Creating a uniapp project using hbuilder x
Creating a uniapp project using hbuilder x
2022-06-25 16:39:00 【Like angels】
Use hbuilder X establish uniapp project
One 、 open hbuilder X Software , top left corner file - newly build - project , Pictured :

Two 、 In the pop-up window , Fill in the project name , Choose your own project case , You can choose according to your own needs vue edition 2/3, Pictured :

3、 ... and 、 By this time your project has been created , Automatically by the hbuilderX open , The general contents of the project documents are shown in the figure :

Four 、 Set the bottom navigation jump , open pages.json file (pages Is the route jump address ,tabBar Is to configure the bottom navigation bar ), If the top navigation wants to add the corresponding button icon , Additable ‘app-plus’ To configure , there ‘fontSrc’ The icon comes from Ali , Here are the steps to download the Alibaba icon , First look at pages.json File configuration of
{
"pages": [{
"path": "pages/index/index",
"style": {
"navigationBarTitleText": " Everyone knows "
}
}, {
"path": "pages/message/index",
"style": {
"navigationBarTitleText": " news ",
"app-plus": {
"titleNView": {
"buttons": [{
"text": "",
"fontSrc": "/static/iconfont/iconfont.ttf",
"fontSize": "20",
"float": "right",
"color": "#7A7E83"
}]
}
}
}
}, {
"path": "pages/personel/index",
"style": {
"navigationBarTitleText": " my "
}
}, {
"path": "pages/collectInfo/index",
"style": {
"navigationBarTitleText": " information acquisition "
}
}, {
"path": "pages/messageDetails/index",
"style": {
"navigationBarTitleText": " News details "
}
}],
"tabBar": {
"color": "#7A7E83",
"selectedColor": "#1296db",
"borderStyle": "black",
"backgroundColor": "#ffffff",
"height": "50px",
"fontSize": "10px",
"iconWidth": "24px",
"spacing": "3px",
"iconfontSrc": "static/iconfont.ttf", // app tabbar typeface .ttf File path app 3.4.4+
"list": [{
"pagePath": "pages/index/index",
"iconPath": "static/home.png",
"selectedIconPath": "static/se_home.png",
"text": " home page "
}, {
"pagePath": "pages/message/index",
"iconPath": "static/message.png",
"selectedIconPath": "static/se_message.png",
"text": " news "
}, {
"pagePath": "pages/personel/index",
"iconPath": "static/mine.png",
"selectedIconPath": "static/se_mine.png",
"text": " my "
}]
},
"globalStyle": {
"navigationBarTextStyle": "black",
"navigationBarTitleText": "uni-app",
"navigationBarBackgroundColor": "#fff",
"backgroundColor": "#fff",
"app-plus": {
"background": "#efeff4"
}
}
}
Ali icon download , Search for the icon you need , Add cart - Add to project - Download to local , This will download a compressed package , After decompressing iconfont.ttf Copy files to your own project , stay pages.json Just introduce the corresponding icon in the :



Final rendering of the page :

Change begins with persistence and commitment.
边栏推荐
- The database records are read through the system time under the Android system, causing the problem of incomplete Reading Records!
- Navicat premium 15 for MAC (database development tool) Chinese version
- Catheon gaming appointed mark Aubrey, former Asia Pacific head of Activision Blizzard, as CEO
- 深入浅出对话系统——自己实现Transformer
- error Parsing error: Unexpected reserved word ‘await‘.
- Webgl and webgpu comparison [4] - uniform
- First knowledge of database
- APIJSON简单使用
- Function and implementation of closures
- Wireshark网卡无法找到或没有显示的问题
猜你喜欢

Day_ fifteen

【機器學習】基於多元時間序列對高考預測分析案例

mac php多版本管理以及安装swoole扩展

Day_ 05

Overall MySQL architecture and statement execution process

Dino: Detr with improved detecting anchor boxes for end to end object detection

Read mysql45 the next day

Unity技术手册 - 干扰/噪音/杂波(Noise)子模块

Bugly hot update usage

error Parsing error: Unexpected reserved word ‘await‘.
随机推荐
Alvaria announces Jeff cotten, a veteran of the customer experience industry, as its new CEO
Day21 multithreading
Catheon gaming appointed mark Aubrey, former Asia Pacific head of Activision Blizzard, as CEO
普通人的2022春招总结(阿里、腾讯offer)
Go language - what is critical resource security?
When inputting text in the shutter textfield, if the page is refreshed, the cursor position will change.
Function and implementation of closures
Go language - lock operation
数据存储和传输文件之XML使用和解析详解
Error: homebrew core is a shallow clone
Div element
Dino: Detr with improved detecting anchor boxes for end to end object detection
Catheon Gaming任命Activision Blizzard前亚太区负责人Mark Aubrey担任首席执行官
GO语言-什么是临界资源安全问题?
Learning notes of rxjs takeuntil operator
Why does golang's modification of slice data affect the data of other slices?
The third day of mysql45
After flutter was upgraded from 2.2.3 to 2.5, the compilation of mixed projects became slower
Overall MySQL architecture and statement execution process
Day_ seventeen