Installation configuration
First we need to install VS, here I install the 2013 version, then we need to go to Egret's official website to download Egret Engine, Egret Wing and Egret vs and install it, while downloading Google Chrome and Egret Inspector and install for debugging. Of course the other software provided by Egret is best installed.
Create a project
The wing provided by Egret is now an integrated IDE, and we open wing to create a new project here, why not create it from vs? Because the project I created here directly from VS will report 404 errors during debugging, which should be caused by the official Egretvs bug, but the project created from wing does not have this problem.
We create a new project in VS that points to the wing-generated directory:
Syntax error resolution method
When there are some grammatical errors, the typescript version of VS is generally less than the typescript version used by Egret, some new features cannot be supported, the workaround is to upgrade vs typescript, and generally upgrade to the current version. The upgrade file is as follows: http://download.microsoft.com/download/4/4/3/443F86B7-A89F-48E6-AC96-0AAC2A910A29/ Ts1.6.2-vuoob.40914.00/typescript_dev12.exe, this is the latest TypeScript version for VS2013, if you need anything else, you can download it on the website:/http www.typescriptlang.org/, find the tool, under the tool choose your corresponding version of the download after installation.
Debug program
We chose Chrome to click this button to debug, of course, in wing can also be debugged:
How to Debug
First of all, our debugging is not done directly in VS or wing, but in Chrome, we press F12 to open the Chrome Developer Tools Panel, select the source page, and we can see that the entire project is visible here, Next we can add a breakpoint directly by clicking on the specified line of the specified code, and when the program runs to that time it will stop and we can view it.
Publishing programs
Publisher we can publish with the corresponding publish option in VS or Wing, Egret will compile typescript into the corresponding JavaScript in the release folder and use the resources exported directly from that folder.
Egret vs. Environment collocation