SC - Electron and Next
July 20, 2025 · View on GitHub
A template to build an ElectronJS app with NextJS
⚠️ See also electron-with-vite
Use
git clone https://github.com/saulotarsobc/electron-next-ts.git;
cd electron-next-ts;
npm install;
npm run dev;
Help
Scripts
dev: Run Electron with development build.build:backend: Build backend with TypeScript.prebuild: Remove build and dist directories.build: Build frontend and backend.build:frontend: Build frontend with Next.js.build:backend: Build backend with TypeScript.postinstall: Install dependencies for Electron.dist: Build and make a distribution package with Electron Builder.
electron-builder Configutarion to this project
...
"build": {
"appId": "br.com.electron.next",
"productName": "SC - Electron and Next",
"files": [
"dist"
],
"directories": {
"output": "out"
},
"win": {
"target": [
"nsis"
],
"artifactName": "${name}-${version}-windows-${arch}.${ext}"
},
"mac": {
"target": "dmg",
"signIgnore": null,
"artifactName": "${productName}-Setup-${version}.${ext}"
},
"linux": {
"target": [
"AppImage",
"deb"
],
"artifactName": "${name}-${version}-linux-${arch}.${ext}"
}
}
...
Git Commands
Release
#! bash
git tag "v\$1"
git push origin --tags