This is the 23rd day of my participation in the November Gwen Challenge. Check out the event details: The last Gwen Challenge 2021

Writing in the front

In the last article, we developed IDE through Hongmeng to become a sample project, this example project for us to show a classic bridge section, that is hello world! Hello World! .

I originally wanted to try it on the real machine today, but I found that the learning order is not quite right. It is better to have a general understanding of hongmeng Project first, and then go to the real machine for the test, otherwise it is probably a little difficult to pack.

Therefore, today I would like to share with you the composition of the Hongmeng Project.

Composition structure of Hongmeng Project

I’ll post a picture for you to see.

Starting with the figure above, there are some key information that comes out. The first is that gradle is used for dependency management. Most of these external files are gradle component-related files.

There are also several files that do not belong to Gradle,

Local. properties: this file records the location of the local SDK and nodeJS external dependent file paths.

In addition to these, the core is the Entry module, which as you can see from the picture is a sub-module of harmonyDemo1.

There are two folders, multiple configuration files; There is nothing to be said for the configuration files.

Libs folder: a folder where imported dependencies are placed, such as a JAR package imported from Java.

SRC: This is our source package.

The source code package is divided into main and ohosTest.

I’m not going to talk about the test case package here, but the main package.

In the main package, as you can see, there are Java, JS, and Resources folders.

Java packages tend to write some configuration, or back-end logic code.

Js package is mainly to write the page UI aspects of the code, later we will create some new files in this package to write a page.

The Resources package is used to place configuration files and data files. Look at the Demo example we created in the previous article, where Hello World, Hello World, reads data from the data file under this package.

One other point to note is the config.json file.

This file is used to configure the overall framework information of the project, which we will learn about later.