Short version:
- Enable nodeIntegration in Electron
- Use WebGPU in a page
- Profit!
Note: You can create background windows. They do not need to visible to run.
git clone https://github.com/greggman/webgpu-with-node-in-electron.git
cd webgpu-with-node-in-electron
npm ci
npm start