Home > Web Front-end > JS Tutorial > Egret Engine Development Guide Compilation Project_node.js

Egret Engine Development Guide Compilation Project_node.js

WBOY
Release: 2016-05-16 16:37:48
Original
1324 people have browsed it

Egret’s compilation function depends on TypeScript’s compilation function. In fact, the compilation process of TypeScript is not the traditional process of translating program source code into a machine-executable secondary copy file. Since the only script that the browser can recognize and execute is JavaScript, the compilation of TypeScript only translates TypeScript into the corresponding JavaScript script.

We don’t need to understand the complicated process inside. We can only understand the compilation process as translating TypeScript into JavaScript code that can be executed by the browser.

This "translation" process is also very simple. We just need to execute a simple command. The command is as follows:

egret build HelloWorld

Where egret build is to perform the "translation" work, and HelloWorld is our project name.

The execution time of the command depends on the size of your project. Usually, when you run a compilation script, the compiler will quickly help you compile your game logic.

When the compilation command is executed, the terminal will automatically jump to the next line. If the command execution fails, the compiler will give you a very detailed error message.

Regarding the error prompt, we will explain it in detail in the debugging and running chapter.

Related labels:
source:php.cn
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template