mirror of
https://github.com/quine-global/hyper.git
synced 2026-01-13 12:38:39 -09:00
14 lines
356 B
JavaScript
14 lines
356 B
JavaScript
import { ipcRenderer, remote } from 'electron';
|
|
const plugins = remote.require('./plugins');
|
|
|
|
export function getConfig () {
|
|
return plugins.getDecoratedConfig();
|
|
}
|
|
|
|
export function subscribe (fn) {
|
|
ipcRenderer.on('config change', fn);
|
|
ipcRenderer.on('plugins change', fn);
|
|
return () => {
|
|
ipcRenderer.removeListener('config change', fn);
|
|
};
|
|
}
|