1.2.0 • Published 5 years ago

electron-load-devtool v1.2.0

Weekly downloads
188
License
MIT
Repository
github
Last release
5 years ago

electron-load-devtool

Build Status All Contributors

Easily Load devtools-extension for electron

why?

Electron supports the Chrome DevTools Extension. But, it's a very bother. This module can load simply for your development environment. And, support some devtool-extensions like redux-devtools by default.

Install

$ npm install --save-dev electron-load-devtool

Usage

const electron = require('electron')
const loadDevtool = require('electron-load-devtool')

electron.app.on('ready', () => {
  const win = new electron.BrowserWindow({ width: 400, height: 400 })
  win.loadURL(`file://${__dirname}/index.html`)

  loadDevtool(loadDevtool.REDUX_DEVTOOLS)

  win.openDevTools()
})

API

loadDevtool(devtoolId, [options])

devtoolId

Type: string

options

enabled

Type: boolean

Only runs when in development, unless overridden by the enabled option. So no need to guard it for production.

name

Type: string Default: google-chrome

If you using chromium on Linux, set chromium.

profile

Type: string Default: Default

Specific Chrome Profile name.

version

Type: string Default: latest

Specific devtools-extension version.

loadDevtool.REDUX_DEVTOOLS

loadDevtool.EMBER_INSPECTOR

loadDevtool.REACT_DEVELOPER_TOOLS

loadDevtool.BACKBONE_DEBUGGER

loadDevtool.JQUERY_DEBUGGER

loadDevtool.ANGULARJS_BATARANG

loadDevtool.VUEJS_DEVTOOLS

loadDevtool.VUEJS_DEVTOOLS_BETA

Contributors

Thanks goes to these wonderful people (emoji key):

akameco💻 📖 🚇mactkg💻Jasper Poppe💻Yoshiyuki Kinjo💻

This project follows the all-contributors specification. Contributions of any kind welcome!

License

MIT © akameco

1.2.0

5 years ago

1.1.0

5 years ago

1.0.0

6 years ago

0.5.1

7 years ago

0.5.0

7 years ago

0.4.0

7 years ago

0.3.0

8 years ago

0.2.0

8 years ago

0.1.0

8 years ago