
Electron Forge Has a Free API: Build, Package, and Publish Desktop Apps Programmatically
What is Electron Forge? Electron Forge is the official toolchain for building Electron applications. It handles everything: scaffolding, building, packaging, code signing, and publishing — with a single unified API. No more juggling electron-builder , electron-packager , and electron-notarize separately. Quick Start npm init electron-app@latest my-app cd my-app npm start You have a working desktop app with hot reload in under 30 seconds. The Forge API Programmatic Build const { api } = require ( " @electron-forge/core " ); // Package your app await api . package ({ dir : " ./my-app " , platform : " darwin " , arch : " arm64 " , }); // Create distributable (DMG, EXE, DEB) await api . make ({ dir : " ./my-app " , platform : " darwin " , arch : " arm64 " , targets : [ " @electron-forge/maker-dmg " ], }); Forge Configuration // forge.config.js module . exports = { packagerConfig : { name : " My App " , icon : " ./assets/icon " , appBundleId : " com.mycompany.myapp " , osxSign : {}, osxNota
Continue reading on Dev.to Tutorial
Opens in a new tab


