Written by Sai Sarath Chandra, Alibaba Billow Tech Share author. Tech Share is Alibaba Cloud’s allurement affairs to animate the administration of abstruse ability and best practices aural the billow community.
Before we allocution about Electron, we charge to booty a footfall aback and see how desktop applications are made. We will additionally assay the issues with the accepted way of developing desktop applications. After that, we will analyze how to actualize a absolutely anatomic balance appliance backend appliance Electron.
Let’s allocution about how Windows-based apps are created. Best bodies use C , C# (C Sharp), VB (Visual Basic) for development. This may accommodate using/reusing some accessible antecedent .NET libraries to accomplish applications beyond all the windows ecosystem like Windows store, windows phone, windows desktop application.
On Mac, we accept a bright absorption of technologies we use to actualize applications. We accept the “Cocoa” layer, which includes all the technologies we crave to actualize the application-user interface. The “Media” band has all the accoutrement and technologies appropriate for the Media operations which accommodate the 2D and 3D animations, Photo and Video editing.
There is additionally a “Core Services” breadth area we can accomplish all the low-level arrangement operations, and cord and abstracts manipulation. “Core OS” exposes all the API/provides functionality for all the CPU and GPU to accomplish high-performance tasks. “Kernel and Accessory Drivers” accommodate abutment for book systems, networking, security, inter-process communication, programming languages, accessory drivers, and extensions to the kernel. This akin additionally exposes the Mach atom environment, accessory drivers, BSD library functions (libSystem), and added low-level components
As you can see, there is a lot you charge to apprentice about the technologies and frameworks in adjustment to advance apps on MacOS. Note that there is no affinity with the Windows technology assemblage we are using.
Linux is one of the best accepted OSs for developers, so we appetite our articles to ability Linux users. I will be talking about both Ubuntu and Linux together. Linux about uses Python or added libraries for the user interface of applications. For Linux, if you charge casework like 3D and 2D rendering, you will charge OpenGL. Linux Atom exposes the low-level functionalities.
Web development is one of the hottest capacity out there and it is no abruptness that the citizenry of web developers is rather high. There are additionally a lot of web developers accessible who can architecture and actualize apps with amazing UI/UX. This is because these technologies are accepted and are actuality acclimated by top companies in the apple for their assembly projects. There are innumerable frameworks out there allowance added teams, backed by tech giants in the industry.
In the fast-paced apple of web development, businesses charge to cope with the accelerated and connected changes in the tech industry. This agency your artefact needs to be prototyped faster and accessible for all platforms, as able-bodied as with a distinct codebase, abutment for added features, and abundant UI/UX. If we aloof depend on accepted methods, we charge a lot of basal and time to accomplish this. Instead, if we use web technologies, we can reclaim a lot of accessible antecedent frameworks and break issues efficiently.
Electron helps us advance cross-platform applications by appliance absolute web technologies. You don’t charge specific skills, for best cases, to advance apps with Electron. If you are a web developer and are absorbed in developing an app with Electron, again accomplish abiding you assay out tutorials that will chase this commodity in this series.
You don’t charge to anticipate abundant back brief your absolute appliance to Electron as the appliance we are creating is a desktop appliance and abstracts stays locally in the system. Because of this, you can ensure abstracts security. In case you charge to abundance abstracts in the cloud, assay whether your billow arrangement has abundant aegis functions advanced to abstain any exceptionable surprises.
Before starting out, you additionally accept to assay whether all the functionalities you are accouterment for your desktop appliance are additionally accessible in Electron. In my experience, Electron provides abundant ascendancy to accept the continued alternate appearance in your application, such as Keyboard Shortcuts. It additionally provides low-level accessibility to the accouterments and operations arrangement components.
Electron thrives in this aspect. If able affliction is taken while developing (load alone what you need), Electron can appearance some abundant assets in the agreement of achievement back compared to built-in applications. Electron saves a lot of time and provides added options to comedy with or advance by accepting a distinct cipher abject for all the above platforms. These are the above problems back we accord with the built-in development of applications, which are all finer apparent by Electron.
However, a lot of bodies say that Electron is actual anamnesis hungry. I accede with this statement, but alone if you advance the applications after able care.
As a Artefact Owner, you don’t charge to advance altered teams for anniversary belvedere and you will be adequate from the altercation of re-explaining your requirements with altered teams. It will additionally abate the auditing assignment to accomplish abiding the artefact has the aforementioned functionality beyond platforms.
As a developer, you charge not anguish about altered codebases. If you appointment a bug on any platform, you can fix it at the cipher base. The bug will never appearance up on added platforms. However, you should still accumulate an eye on the OS akin functionalities.
Because we are appliance a distinct cipher base, it agency we can use this for both web applications and desktop applications. We are, in a way, additionally reusing the abject cipher beyond altered platforms back we “code once, administer everywhere.”
The added accepted frameworks we use, the added abutment we get. This, in turn, gives us added accessible antecedent libraries we can reclaim and the decreased time to assembly but with added features.
This is one of the absorbing aspects of Electron. There is an electron-packager bore accessible that helps us array the accomplished cipher abject into the corresponding packages. Although bodies agitation that Electron takes a lot of memory, as I said, Electron needs a little affliction during development to abstain this.
With web technologies, you are accessible to assorted technologies that accommodate abundant User Interface (UI) and User Acquaintance (UX) to all your users with abundant comfort. Also, you can be abiding that you are accouterment the aforementioned acquaintance to all your users beyond altered platforms.
You will save a lot of development time and money because, for the tech assemblage we use, there are a lot of developers who can do it for beneath and accomplish acceptable results. You can save a lot of time appliance the distinct cipher abject and any developer can assignment on anything.
When we allocution about any technology we charge to allocution a little about the history abaft it. Let’s briefly attending at the history of Electron.
You can additionally use added frameworks on top of the basal bureaucracy like Next.js, Vue.js, and Angular 5. This will accomplish your development easier by befitting the applications added pre-defined and modularized, which in about-face makes debugging and apperception easier. You can additionally actualize unit-test cases to accomplish abiding your changes are not breaking any absolute functionality.
I accept created a simple use case diagram which shows how electron works at the amount level.
Let’s see how Electron works.
The applicant launches the Electron application, about from a adopted belvedere like Windows/MacOS/Linux-based Ubuntu.
The application makes a appeal to the window appliance the capital process.
Main Process: This is amenable for sending and receiving requests and appointment abstracts amid altered windows; you can anticipate of it as a axial barter for all the windows. All memory management, like conception and aition of windows, is handled here.
The main process makes a appeal to barrage a window forth with Renderer.js (Renderer process).
Renderer Process: This is the added JS book we will advertence in every HTML book in the window. You can admission the complete DOM in the Renderer Process. You can additionally use it in the HTML but using the Renderer Action is a cleaner way to do that. As your appliance grows, you will acknowledge this approach.
A assurance in window will be launched and attaches to the capital process, accessible for operations.
The user enters their login information, again you will handle the on bang in the renderer action and accomplish a appeal to the capital action for ablution the Artefact Window.
The capital action will accept the corresponding advice via an accident adviser and launch the Artefact window based on the appeal appliance the Renderer Process.
This bend continues for the accomplished appliance until the complete use case is solved.
Our tutorials that chase this commodity will altercate these concepts with a alive appliance created appliance Electron, with the backend database based on Alibaba Billow ApsaraDB for MongoDB.
Desktop applications are decumbent to accident abstracts during a system blast or any accustomed calamities. To save our adored data, we will be aing our activity with a backend deployed on the cloud. We will be assuming some abstracts assay on the abstracts stored.
The acumen we accept Alibaba Billow ApsaraDB for MongoDB because of the simple low amount and aerial availability. I will authenticate my acquaintance of how we can deeply affix to this accepted account and advantage it to our use.
The tutorials will be a simple two-part, step-by-step tutorial, which clarifies a lot of concepts if you are new to Electron. Part 1 of the tutorial talks about designing the front-end of the app and Part 2 of the tutorial discusses the capacity of the backend with ApsaraDB for MongoDB.
We will see in detail how an Electron app is created from blemish with altered apparatus like ipcRenderer, ipcMain, book functionality. We will additionally analyze how to package/build an Electron app for assembly and administration purposes. At the end of the tutorial, you should be able to actualize alternate archive and use the accessible antecedent libraries to actualize an alarming UI in no time.
Whenever appliance a new technology, you are added acceptable than not to appointment some roadblocks. That’s why I’ll allotment some tips and tricks, as able-bodied as accord you a heads-up for some pitfalls I faced during my development, which can save you a lot of time.
Then we will actualize the backend account based on Node.js appliance the Express bulge bore and host it in the ECS instance. We will betrayal this publically for the Electron App to access.
13 Things You Most Likely Didn’t Know About Amazing Charts Client Portal | Amazing Charts Client Portal – amazing charts client portal
| Delightful to be able to my blog, in this moment I am going to teach you with regards to amazing charts client portal