Create a gist now

Instantly share code, notes, and snippets.

Create a new window with an icon in Electron on Linux
app.on ("ready", function () {
var nativeIcon = NativeImage.createFromPath (__dirname + "/" + "pork.png");
mainWindow = new BrowserWindow ({
width: 1100,
height: 1000,
icon: nativeIcon
mainWindow.loadURL('file://' + __dirname + '/index.html');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment