![electron cross compile mac on linux electron cross compile mac on linux](https://i1.wp.com/www.alphr.com/wp-content/uploads/2015/04/code43.png)
It seems like a good idea, but it is a bit in conflict with our goal. A shell is directly set on it, which provides visual interaction, and then helps you to perform the corresponding gulp tasks. In this way, any gulp process does not need to be changed. Package.json Consistent with the normal node program, the main.jsAs the starting entry file of the program, the basic contents are as follows: ) We have the following directory structure: electron-quick-start/ I believe you can see that there is a certain understanding of node, so the installation of node will not be described here.
![electron cross compile mac on linux electron cross compile mac on linux](https://miro.medium.com/max/1280/1*dmtb63N_YaSX4d3nE4WB1w.png)
Electron cross compile mac on linux code#
Maybe you don’t know, Visual Studio Code 、 wordpressand slackThe clients are all based on electron. Therefore, using electron to write cross platform applications is very appropriate. You can also think of electron as a small chrome kernel browser controlled by JavaScript.īecause of the built-in chromium kernel and node, we don’t need to care about the front-end compatibility, you can even write -webkit- onlyWe also don’t need to care about the compatibility of some node modules that need to be compiled, because the node version is fixed. What can electron do?Įlectron has built-in chromium kernel and node, so it can use HTML and CSS to implement GUI interface, and JavaScript to call rich native API to realize desktop application. It was originally released by GitHub AtomThe atom shell derived from the editor was renamed electron. What is electron?Įlectron is a framework that can use web technology to develop cross platform desktop applications. As a front-end, it is exciting to be able to use a familiar language to quickly realize the desktop application that you want.Īt present, the common ones are NW、 heX、 Electron。 Today, let’s start with electron. Now, with HTML, JavaScript, CSS Node.js Writing desktop applications is not a new thing.