Home Web Front-end JS Tutorial How to use HBuilder to package App

How to use HBuilder to package App

Sep 06, 2017 pm 01:46 PM
hbuilder Pack conduct

HBuilder is a web development IDE launched by DCloud (Digital Paradise) that supports HTML5. This software can not only support web code writing, but also package already written project codes into mobile APPs.

HBuilder provides two types of packaging: cloud packaging and local packaging. The characteristic of cloud packaging is that DCloud has officially configured a native packaging environment and can compile HTML and other files into native installation packages. .

1. Download HBuilder, register and log in. First open "File" - "New" - "Mobile APP", enter the "Application Name", and the "Location" can be selected according to your needs. "Select Template" recommends choosing an empty template;

2. After the new creation is completed, the newly created project directory will be displayed in the project manager, in which the css, img, js and index.html files can be deleted, modified or replaced.

The unpackage folder is where the app icon and startup interface pictures are placed.

The manifest.json file is the configuration file of the mobile App. It is used to specify the display name, icon, application entry file address and required device permissions and other information. Users can use HBuilder Use the visual interface view or source code view to configure the mobile App information.

3. If you delete the css, img, js folder and index.html file, copy other project files to the file accordingly. folder, please note that the reference path in the html file needs to be correct.

Copy the project as shown below:

4, Copy the file After completion, refresh the update and double-click to open the manifest.json file to configure the App.

appid: Click on the cloud to get it. Version number: Edit as needed. Page entry: The default is index.html. Change the startup page of the APP according to your project needs. Application description: Fill it out yourself. Whether the application is displayed in full screen: Check it to display in full screen.

5. Icon configuration: Click the icon configuration at the bottom of the page to configure the APP display icon.

1) Click the square box with the "+" sign, select the path of the icon material to find the icon material, and then click the "Automatically generate all icons and replace" button to complete the icon generation and replacement .

2), the generated icon is automatically in the unpackage folder

6, Startup image (splash) configuration, click to switch to startup image configuration

1), Startup options: Default

2), set the startup image, depending on whether it is an Android or iOS platform, and then make a startup image according to different devices

3), create a new one under unpackage→res file Name the file "splash" and put the completed startup image into this file.

4), click "Select" in the startup image settings and find the startup image you just put in

7, SDK configuration: Configure if necessary, if not, just default.

8. Module permission configuration: Configure if necessary, otherwise just default.

9, page reference relationship:

First click "Scan Code", then click on the index.html file on the left

What does this function mean: Click on the html file on the left, and different files, pictures, etc. will be displayed on the right. It can represent the resources required when loading the html file on the left.

10, Code view: Check whether the settings are correct in the code view, and then ctrl+s to save.

11, set the configuration options and officially enter the packaging stage

HBuilder click: "Release"-"Release as native installation package" Start packaging

Here is an introduction to iOS packaging

1), if you choose the jailbreak package, it will not An Apple certificate is required and the package can be successfully packaged with default settings. However, the packaged App can only be installed on jailbroken phones, and cannot be installed without jailbreak.

2), if you use Apple certificate, here is a tool to apply for iOS certificate Appuploader. Without an Apple paid developer account, you can use Appuploader to apply for an ios test certificate, package the ipa and install it on a non-jailbroken device using a normal Apple ID.

Tool installation URL: http://www.applicationloader.net/blog/zh/72.html

No developer account required Tutorial on applying for iOS certificate: http://www.applicationloader.net/blog/zh/1073.html

12. Click OK after successful submission. Check the App packaging status

When the packaging is successful, you can click manual download and install it on the iPad through the third-party tool Apple Assistant.

13. Debugging and installing the simulator

If you need to debug locally on the computer You need to install the simulator, please refer to http://ask.dcloud.net.cn/article/151 How to install and configure the mobile phone simulator, or in HBuilder→→Run→→Mobile phone run→→How to install and configure the mobile phone simulator to enter Check.

If you need to install it on a mobile phone for real-machine debugging, connect the mobile phone to the computer with a data cable, then restart HBuilder→→run→→run the phone→→connect to the real machine.

The above is the detailed content of How to use HBuilder to package App. For more information, please follow other related articles on the PHP Chinese website!

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Share an easy way to package PyCharm projects Share an easy way to package PyCharm projects Dec 30, 2023 am 09:34 AM

Share the simple and easy-to-understand PyCharm project packaging method. With the popularity of Python, more and more developers use PyCharm as the main tool for Python development. PyCharm is a powerful integrated development environment that provides many convenient functions to help us improve development efficiency. One of the important functions is project packaging. This article will introduce how to package projects in PyCharm in a simple and easy-to-understand way, and provide specific code examples. Why package projects? Developed in Python

How to use Python regular expressions for code packaging and distribution How to use Python regular expressions for code packaging and distribution Jun 23, 2023 am 09:31 AM

As the Python programming language becomes increasingly popular, more and more developers are starting to write code in Python. But in actual use, we often need to package these codes and distribute them to others for use. This article will introduce how to use Python regular expressions for code packaging and distribution. 1. Python code packaging In Python, we can use tools such as setuptools and distutils to package our code. These tools can convert Python files, modules

How to import projects with hbuilder - How to import projects with hbuilder How to import projects with hbuilder - How to import projects with hbuilder Mar 05, 2024 pm 09:19 PM

Many programmers are using hbuilder software, but do you know how hbuilder imports projects? The following article brings you how to import projects with hbuilder. Let's take a look below. Open hbuilder and enter the main interface, prepare the downloaded project and record the path. Find "File" in the navigation bar of the hbuilder main interface, select "Import", continue to select import from the local directory, and find the prepared project file. Finally, check the hbuilder project bar and you can see that the import was successful.

How to use pkg to package Node.js project into an executable file? How to use pkg to package Node.js project into an executable file? Jul 26, 2022 pm 07:33 PM

How to package nodejs executable file with pkg? The following article will introduce to you how to use pkg to package a Node.js project into an executable file. I hope it will be helpful to you!

Detailed explanation of VSCode functions: How does it help you improve work efficiency? Detailed explanation of VSCode functions: How does it help you improve work efficiency? Mar 25, 2024 pm 05:27 PM

Detailed explanation of VSCode functions: How does it help you improve work efficiency? With the continuous development of the software development industry, developers' pursuit of work efficiency and code quality have become important goals in their work. In this process, the choice of code editor becomes a key decision. Among many editors, Visual Studio Code (VSCode for short) is loved by the majority of developers for its powerful functions and flexible scalability. This article will introduce some functions of VSCode in detail and discuss

Declaration of Independence for Python Applications: PyInstaller's Road to Freedom Declaration of Independence for Python Applications: PyInstaller's Road to Freedom Feb 20, 2024 am 09:27 AM

PyInstaller: Independence of Python applications PyInstaller is an open source python packaging tool that packages Python applications and their dependencies into an independent executable file. This process eliminates dependence on the Python interpreter while allowing applications to run on a variety of platforms, including Windows, MacOS, and Linux. Packaging Process The packaging process of PyInstaller is relatively simple and involves the following steps: pipinstallpyinstallerpyinstaller--onefile--windowedmain.py--onefile option creates a single

What does linux packaging mean? What does linux packaging mean? Feb 23, 2023 pm 06:30 PM

In Linux, packaging refers to a collection of files or directories, and this collection is stored in a file; simply put, packaging refers to turning a large number of files or directories into a total file. The packed file is not compressed, so the space it takes up is the sum of all files and directories in it.

Transform Python code into an independent application: the alchemy of PyInstaller Transform Python code into an independent application: the alchemy of PyInstaller Feb 19, 2024 pm 01:27 PM

PyInstaller is an open source library that allows developers to compile Python code into platform-independent self-contained executables (.exe or .app). It does this by packaging Python code, dependencies, and supporting files together to create standalone applications that can run without installing a Python interpreter. The advantage of PyInstaller is that it removes dependency on the Python environment, allowing applications to be easily distributed and deployed to end users. It also provides a builder mode that allows users to customize the application's settings, icons, resource files, and environment variables. Install PyInstal using PyInstaller to package Python code

See all articles