Plugin Migration Guide from v5 to v6
View in MarkdownSourceNew ipm CLI tool
In v6, there is a new CLI tool named ipm (Inkdrop Plugin Manager) for publishing plugins.
npm install -g @inkdropapp/ipm-cli
ipm configure
Check out the repository for more details.
@electron/remote is deprecated
remote.dialog → inkdrop.dialog
Before:
const remote = require('@electron/remote')
const { dialog } = remote
return dialog.showOpenDialog(
inkdrop.window,
{
...
})
After:
return inkdrop.dialog.showOpenDialog({
...
})
The inkdrop.window argument is no longer required.
inkdrop.window.on()
Before:
inkdrop.window.on('focus', this.handleAppFocus)
After:
const sub = inkdrop.window.onFocus(this.handleAppFocus)
// Unsubscribe
sub.dispose()