Electron Apr 2026
Expose specific functions to the window object that trigger IPC (Inter-Process Communication) events.
: Use C++ or Rust via node-addon-api for high-performance tasks. Resources for Scaling Native Code and Electron
: Create custom system tray icons or native context menus. Electron
To develop a new feature in an application, you typically need to bridge the gap between your web-based user interface ( Renderer process ) and the underlying operating system ( Main process ) using a Preload script for security . 1. Define the Backend Logic (Main Process)
Listen for custom events using ipcMain.on or ipcMain.handle . Expose specific functions to the window object that
: Handle custom URL protocols to open your app from a browser.
This is where you build your feature's look and feel using standard web tech (HTML, CSS, JavaScript) or frameworks like or Vue . Add event listeners to buttons or UI elements. To develop a new feature in an application,
Because of , the renderer cannot access Node.js or Electron APIs directly. Use the contextBridge API to create a "safe" bridge.