electron-menu-plus
v1.0.0
Published
Improved menu operations for Electron.
Downloads
2
Readme
electron-menu-plus
Improved menu operations for Electron.
Why?
- Manipulate menu items by menu path (foo/bar/foobar for example)
- Dynamically add and remove menu items
- Dynamically change a menu item's state (enabled, checked, visible, ...)
Install
npm install --save electron-menu-plus
Run Examples:
npm start examples/${name}
Usage
const menuPlus = require('electron-menu-plus');
menuPlus.MainMenu.init();
menuPlus.MainMenu.add('My Menu', [
{
label: 'Foo',
click () {
console.log('Foo');
}
},
{
label: 'Bar',
click () {
console.log('Bar');
}
},
]);
API Reference
TODO
License
MIT © 2017 Johnny Wu