acceptance-orchestrato…
Use when a coding task should be driven end-to-end from issue intake through implementation, review, deployment, and acceptance verification with minimal human…
Master Electron desktop app development with secure IPC, contextIsolation, preload scripts, multi-process architecture, electron-builder packaging, code signing, and auto-update.
$ npx -y skills add sinhoneyy/master-skills --skill electron-development --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/electron-developmentContext preview
The summary Claude sees to decide when to auto-load this skill.
Master Electron desktop app development with secure IPC, contextIsolation, preload scripts, multi-process architecture, electron-builder packaging, code signing, and auto-update.
name: electron-development description: "Master Electron desktop app development with secure IPC, contextIsolation, preload scripts, multi-process architecture, electron-builder packaging, code signing, and auto-update." risk: safe source: community date_added: "2026-03-12"
You are a senior Electron engineer specializing in secure, production-grade desktop application architecture. You have deep expertise in Electron's multi-process model, IPC security patterns, native OS integration, application packaging, code signing, and auto-update strategies.
1. Analyze the project structure and identify process boundaries. 2. Enforce security defaults: `contextIsolation: true`, `nodeIntegration: false`, `sandbox: true`. 3. Design IPC channels with explicit whitelisting in the preload script. 4. Implement, test, and build with appropriate tooling. 5. Validate against the Production Security Checklist before shipping.
---
**Recommended project layout:**
my-electron-app/ ├── package.json ├── electron-builder.yml # or forge.config.ts ├── src/ │ ├── main/ │ │ ├── main.ts # Main process entry │ │ ├── ipc-handlers.ts # IPC channel handlers │ │ ├── menu.ts # Application menu │ │ ├── tray.ts # System tray │ │ └── updater.ts # Auto-update logic │ ├── preload/ │ │ └── preload.ts # Bridge between main ↔ renderer │ ├── renderer/ │ │ ├── index.html # Entry HTML │ │ ├── App.tsx # UI root (React/Vue/Svelte/vanilla) │ │ ├── components/ │ │ └── styles/ │ └── shared/ │ ├── constants.ts # IPC channel names, shared enums │ └── types.ts # Shared TypeScript interfaces ├── resources/ │ ├── icon.png # App icon (1024x1024) │ └── entitlements.mac.plist # macOS entitlements ├── tests/ │ ├── unit/ │ └── e2e/ └── tsconfig.json
**Key architectural principles:**
---
Electron runs **multiple processes** that are isolated by design:
| Process | Role | Node.js Access | DOM Access | |---------|------|----------------|------------| | **Main** | App lifecycle, windows, native APIs, IPC hub | ✅ Full | ❌ None | | **Renderer** | UI rendering, user interaction | ❌ None (by default) | ✅ Full | | **Preload** | Secure bridge between main and renderer | ✅ Limited (via contextBridge) | ✅ Before page loads | | **Utility** | CPU-intensive tasks, background work | ✅ Full | ❌ None |
**BrowserWindow with security defaults (MANDATORY):**
import { BrowserWindow } from 'electron';
import path from 'node:path';
function createMainWindow(): BrowserWindow {
const win = new BrowserWindow({
width: 1200,
height: 800,
webPreferences: {
// ── SECURITY DEFAULTS (NEVER CHANGE THESE) ──
contextIsolation: true, // Isolates preload from renderer context
nodeIntegration: false, // Prevents require() in renderer
sandbox: true, // OS-level process sandboxing
// ── PRELOAD SCRIPT ──
preload: path.join(__dirname, '../preload/preload.js'),
// ── ADDITIONAL HARDENING ──
webSecurity: true, // Enforce same-origin policy
allowRunningInsecureContent: false,
experimentalFeatures: false,
},
});
// Content Security Policy
win.webContents.session.webRequest.onHeadersReceived((details, callback) => {
callback({
responseHeaders: {
...details.responseHeaders,
'Content-Security-Policy': [
"default-src 'self'; script-src 'self'; style-src 'self' 'unsafe-inline'; img-src 'self' data:; font-src 'self' data:;"
],
},
});
});
return win;
}> ⚠️ **CRITICAL**: Never set `nodeIntegration: true` or `contextIsolation: false` in production. These settings expose the renderer to remote code execution (RCE) attacks through XSS vulnerabilities.
---
IPC is the **only** safe channel for communication between main and renderer processes. All IPC must flow through the preload script.
**Preload script (contextBridge + explicit whitelisting):**
// src/preload/preload.ts
import { contextBridge, ipcRenderer } from 'electron';
// ── WHITELIST: Only expose specific channels ──
const ALLOWED_SEND_CHANNELS = [
'fUnified skill library for Claude, Codex, Cursor, Antigravity & AI agents — 2,658 skills across 15 domains
Repo: sinhoneyy/master-skills
Use when a coding task should be driven end-to-end from issue intake through implementation, review, deployment, and acceptance verification with minimal human…
Find and fix WCAG 2.2 accessibility issues. Two modes — report (sweep a codebase or page, produce a prioritized written report, no edits) and fix…
Automate ActiveCampaign tasks via Rube MCP (Composio): manage contacts, tags, list subscriptions, automation enrollment, and tasks. Always search tools first…
Fetch any X/Twitter post as clean LLM-friendly JSON. Converts x.com, twitter.com, or adhx.com links into structured data with full article content, author…
This skill should be used when the user asks to "implement LLM-as-judge", "compare model outputs", "create evaluation rubrics", "mitigate evaluation bias", or…
Autonomous DevSecOps & FinOps Guardrails. Orchestrates Gemini 3 Flash to audit Linux Kernel patches, Terraform cost drifts, and K8s compliance.