electron-react-titlebar
A github desktop style title bar component for electron.
Installation
npm i --save electron-react-titlebar
Example
You should have electron installed first.
electron app
Usage
import { TitleBar } from 'electron-react-titlebar'
import 'electron-react-titlebar/assets/style.css'
ReactDOM.render(
<TitleBar menu={menuTemplate} icon={iconPath} />,
document.querySelector('title-bar')
)Options
children
Elements to be rendered in between the menu and the window controls (optional).
disableMinimize
Disable minimize button
disableMaximize
Disable maximize button
icon
Path to icon file.
menu
Menu template of Electron's Menu
Note: electron-react-titlebar is supporting a subset of Electron's MenuItem.
Supported options:
click- supportedtype-submenuis not supported.label- supportedenabled- supportedvisible- supportedchecked- supported