rhysd / electron-about-window

'About This App' mini-window for Electron apps
https://www.npmjs.com/package/about-window
MIT License
409 stars 46 forks source link

Electron version shown instead of application version in dev mode #73

Open vanowm opened 2 years ago

vanowm commented 2 years ago

In dev mode electron version shown instead of application version. Perhaps the version should be pulled directly from package.json or at least let the developer override it.

For now I'm using this work around:

cons info = {
    icon_path: 'path/to/icon.png'
    app,
    BrowserWindow,
    ipcMain,
}
const win = openAboutWindow(info);
const version = require("../package.json").version;

win.webContents.once('dom-ready', () => {
    win.webContents.send('about-window:info', info, info.product_name, version);
});