fix: shared-lib not found

https://github.com/sourcygen/electron-angular-quick-start/issues/4
This commit is contained in:
Amadou Ada DIENE
2021-07-22 14:06:31 +02:00
parent cd7a150c1d
commit 99742e3dc1
14 changed files with 74 additions and 4 deletions

View File

@@ -0,0 +1,10 @@
export declare class WindowApiConst {
/** Channel used by the renderer process to send data to the main process */
static readonly MULTIPLES_INPUT = 'getMultiplesInput';
/** Channel used by the renderer process to receive data from the main process */
static readonly MULTIPLES_OUTPUT = 'getMultiplesOutput';
/** Whitelist of the safe channels to use when sending data to the main process */
static readonly SENDING_SAFE_CHANNELS: string[];
/** Whitelist of the safe channels to use when receiving data from the main process */
static readonly RECEIVING_SAFE_CHANNELS: string[];
}

View File

@@ -0,0 +1,10 @@
export class WindowApiConst {}
/** Channel used by the renderer process to send data to the main process */
WindowApiConst.MULTIPLES_INPUT = 'getMultiplesInput';
/** Channel used by the renderer process to receive data from the main process */
WindowApiConst.MULTIPLES_OUTPUT = 'getMultiplesOutput';
/** Whitelist of the safe channels to use when sending data to the main process */
WindowApiConst.SENDING_SAFE_CHANNELS = [WindowApiConst.MULTIPLES_INPUT];
/** Whitelist of the safe channels to use when receiving data from the main process */
WindowApiConst.RECEIVING_SAFE_CHANNELS = [WindowApiConst.MULTIPLES_OUTPUT];
//# sourceMappingURL=window-api-consts.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"window-api-consts.js","sourceRoot":"","sources":["../../apis/window-api-consts.ts"],"names":[],"mappings":"AAAA,MAAM,OAAO,cAAc;;AACzB,4EAA4E;AACrD,8BAAe,GAAG,mBAAmB,CAAC;AAE7D,iFAAiF;AAC1D,+BAAgB,GAAG,oBAAoB,CAAC;AAE/D,kFAAkF;AAC3D,oCAAqB,GAAG;IAC7C,cAAc,CAAC,eAAe;CAC/B,CAAC;AAEF,sFAAsF;AAC/D,sCAAuB,GAAG;IAC/C,cAAc,CAAC,gBAAgB;CAChC,CAAC"}

View File

@@ -0,0 +1,14 @@
export interface WindowApi {
/**
* This method is used by the renderer process to receive data from the main process
* @param channel used by the renderer to receive data and by the main to send them
* @param func the callback function to execute when data are available
*/
receive<Out>(channel: string, func: (output: Out) => void): void;
/**
* This method is used by the renderer process to send data to the main process
* @param channel used by the renderer to send data and by the main to receive them
* @param data the data sent by the renderer process to the main process
*/
send<In>(channel: string, input: In): void;
}

View File

@@ -0,0 +1,2 @@
export {};
//# sourceMappingURL=window-api.js.map

View File

@@ -0,0 +1 @@
{"version":3,"file":"window-api.js","sourceRoot":"","sources":["../../apis/window-api.ts"],"names":[],"mappings":""}