Understanding Electron's Architecture
Get a clear mental model of how Electron combines Chromium and Node.js, and how the main and renderer processes work together before you build bigger apps.
Two Worlds in One App
Electron fuses two runtimes: Chromium for the UI and Node.js for system access. Grasping how they coexist is the foundation of every app.
The Main Process
Each app has exactly one main process. It runs your entry file, controls the lifecycle, and creates BrowserWindow instances with full Node access.
const { app, BrowserWindow } = require('electron');
app.whenReady().then(() => {
new BrowserWindow({ width: 800, height: 600 });
});All lessons in this course
- What is Electron?
- Setting Up Your Dev Environment
- Your First Electron Application
- Understanding Electron's Architecture