Setting cookies from Electron code looks too complicated - I'll go with the simpler mechanism where every new BrowserWindow hits /-/auth-app-user?redirect=/-/plugins which accepts the Authorization: Bearer xxx token from #53 and redirects with the newly set cookie.
Originally posted by @simonw in https://github.com/simonw/datasette-app/issues/37#issuecomment-912879644