Skip to content

Commit 950282e

Browse files
Merge pull request #36 from NBoychev/master
Use CRA compatible constants
2 parents 2ddb8fb + e7d6d31 commit 950282e

File tree

2 files changed

+11
-17
lines changed

2 files changed

+11
-17
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "electron-push-receiver",
3-
"version": "2.1.1",
3+
"version": "2.1.2",
44
"description": "A module to receive FCM notifications in electron",
55
"main": "src/index.js",
66
"repository": "https://github.com/MatthieuLemoine/electron-push-receiver",

src/constants/index.js

Lines changed: 10 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,12 @@
1-
// Event to be sent from renderer process to trigger service start
2-
const START_NOTIFICATION_SERVICE = 'PUSH_RECEIVER:::START_NOTIFICATION_SERVICE';
3-
// Event sent to the renderer process once the service is up
4-
const NOTIFICATION_SERVICE_STARTED = 'PUSH_RECEIVER:::NOTIFICATION_SERVICE_STARTED';
5-
// Event sent to the renderer process if an error has occured during the starting process
6-
const NOTIFICATION_SERVICE_ERROR = 'PUSH_RECEIVER:::NOTIFICATION_SERVICE_ERROR';
7-
// Event sent to the renderer processs when a notification has been received
8-
const NOTIFICATION_RECEIVED = 'PUSH_RECEIVER:::NOTIFICATION_RECEIVED';
9-
// Event sent to the renderer processs when the FCM token has been updated
10-
const TOKEN_UPDATED = 'PUSH_RECEIVER:::TOKEN_UPDATED';
11-
121
module.exports = {
13-
START_NOTIFICATION_SERVICE,
14-
NOTIFICATION_SERVICE_STARTED,
15-
NOTIFICATION_SERVICE_ERROR,
16-
NOTIFICATION_RECEIVED,
17-
TOKEN_UPDATED,
2+
// Event to be sent from renderer process to trigger service start
3+
START_NOTIFICATION_SERVICE: 'PUSH_RECEIVER:::START_NOTIFICATION_SERVICE',
4+
// Event sent to the renderer process once the service is up
5+
NOTIFICATION_SERVICE_STARTED: 'PUSH_RECEIVER:::NOTIFICATION_SERVICE_STARTED',
6+
// Event sent to the renderer process if an error has occured during the starting process
7+
NOTIFICATION_SERVICE_ERROR: 'PUSH_RECEIVER:::NOTIFICATION_SERVICE_ERROR',
8+
// Event sent to the renderer processs when a notification has been received
9+
NOTIFICATION_RECEIVED: 'PUSH_RECEIVER:::NOTIFICATION_RECEIVED',
10+
// Event sent to the renderer processs when the FCM token has been updated
11+
TOKEN_UPDATED: 'PUSH_RECEIVER:::TOKEN_UPDATED',
1812
};

0 commit comments

Comments
 (0)