Skip to main content
prompt GP ChatGPT

Electron App taste — ChatGPT prompt: what it does, how to install

Electron App taste is a prompt for ChatGPT, Claude.ai, and Claude Code that sets security standards for desktop apps during architecture design and Electron coding.

CC0-1.0 ★ 178,201 updated 2026-10-24

Open on GitHub

What Electron App taste does

This prompt establishes rules for security, architecture, and packaging of desktop software. Protection relies on context isolation in BrowserWindow, disabling Node API in the renderer via nodeIntegration, and filtering IPC calls through contextBridge.

The document outlines navigation handling, secret storage with safeStorage, building via electron-builder, and testing in Playwright. Heavy tasks move to worker threads, and packaging for macOS and Windows requires code signing.

To use it in Claude Code, place the file in .claude/commands/prompts.csv.md.

What it helps with

  • configure context isolation in BrowserWindow
  • validate IPC messages in the main process
  • set up a secure preload script
  • configure packaging with electron-builder

Example prompts for the agent

  • Apply Electron App taste security standards to our desktop app
  • Check window architecture against Electron App taste rules
  • Write a secure IPC handler following Electron App taste

How to install Electron App taste

How to use

Paste the text at the start of a chat or into project instructions

Questions about Electron App taste

How to install Electron App taste in Claude Code?

Place the file in .claude/commands/prompts.csv.md.

What does Electron App taste do?

It sets rules for secure development and architecture of Electron desktop apps.

What technologies does the prompt use?

The prompt covers TypeScript, Electron Forge, electron-builder, Vite, and Playwright.

Source text

prompts.csv · CC0-1.0
# Electron App taste of a desktop developer who takes security seriously
- Keep `contextIsolation: true` and `nodeIntegration: false` on every `BrowserWindow`; these are non-negotiable defaults. Confidence: 0.98
- Enable `sandbox: true` for renderers and give each window the smallest preload script it needs. Confidence: 0.90
- Expose a narrow, typed API from the preload with `contextBridge.exposeInMainWorld` instead of passing `ipcRenderer` through. Confidence: 0.95
- Use `ipcMain.handle` and `ipcRenderer.invoke` for request and response calls, and validate every argument in the main process. Confidence: 0.90
- Check the sender frame on IPC messages so only your own pages can call privileged handlers. Confidence: 0.80
- Set a strict Content Security Policy and never load remote code into a window with privileged preload access. Confidence: 0.90
- Block unexpected navigation with `will-navigate` and `setWindowOpenHandler`, and open external links in the system browser with `shell.openExternal` after allowlisting the URL. Confidence: 0.90
- Serve local content through a custom protocol instead of `file://` so origin rules and CSP behave predictably. Confidence: 0.75
- Write the main, preload and renderer code in TypeScript, sharing IPC channel types from one module. Confidence: 0.85
- Use Electron Forge or electron-builder with Vite for building and packaging rather than a hand-rolled script. Confidence: 0.80
- Keep heavy work out of the main process; use utility processes or worker threads so the UI never freezes. Confidence: 0.85
- Track the latest supported Electron major and upgrade at least every quarter, since each release carries Chromium security fixes. Confidence: 0.85
- Sign and notarize macOS builds and sign Windows installers before anyone outside the team installs them. Confidence: 0.95
- Ship auto-updates through `autoUpdater` or electron-updater with signed releases and a staged rollout. Confidence: 0.80
- Enable Electron fuses to disable `RunAsNode` and Node CLI inspection in production builds. Confidence: 0.75
- Persist settings and window state in the user data directory, and store secrets with `safeStorage` or the OS keychain, never in plain JSON. Confidence: 0.85
- Restore window size and position on launch and handle multiple displays gracefully. Confidence: 0.70
- Respect platform conventions: the macOS app menu, Windows tray behavior and native keyboard shortcuts. Confidence: 0.75
- Watch bundle size and startup time, lazy-load heavy modules and avoid shipping dev dependencies in the app archive. Confidence: 0.75
- Collect crash reports with `crashReporter` or Sentry and log main-process errors to a rotating file. Confidence: 0.75
- Run end-to-end tests with Playwright's Electron support against the packaged app, not only the dev build. Confidence: 0.70

© f · CC0-1.0 · f/prompts.chat

Similar prompts

All prompts for Security →

From the same set218

The whole set →
RAG Pipeline taste RAG Pipeline taste — a prompt for ChatGPT defines engineering standards for building retrieval systems and evaluating generation accuracy. GP ChatGPT ★ 178,201repo stars Makefile taste The Makefile taste ChatGPT prompt sets conventions for project Makefiles. It guides target structure, recipes, and dependencies so make can act as the project’s front door. GP ChatGPT ★ 178,201repo stars API Deprecation and Sunset Plan Builder (YAML) API Deprecation and Sunset Plan Builder (YAML) is a prompt that turns API deprecation details into a structured YAML sunset plan with timelines, communication strategies, and migration steps. GP ChatGPT ★ 178,201repo stars Nginx Config taste The Nginx Config taste ChatGPT prompt sets conventions for Nginx configuration and operations. Use it while configuring virtual hosts, HTTPS, or proxy routes. GP ChatGPT ★ 178,201repo stars Pytest taste Pytest taste is a ChatGPT prompt that sets conventions for Python tests written with pytest. It guides test structure, fixtures, assertions, and suite configuration. GP ChatGPT ★ 178,201repo stars Angular App taste Angular App taste — a prompt for ChatGPT and Claude Code that enforces modern enterprise Angular architectural standards. Sets rules for standalone components, signals, and native control flow. GP ChatGPT ★ 178,201repo stars SQLite taste SQLite taste — a prompt for ChatGPT that gives practical SQLite guidance. It covers database settings, schema changes, query planning, and backups. GP ChatGPT ★ 178,201repo stars Dependency Management taste Dependency Management taste — a prompt for ChatGPT and Claude.ai that configures AI around a strict dependency management philosophy. Prevents surprise breakages. GP ChatGPT ★ 178,201repo stars

Project sponsors

Companies that keep this analytics open