diff --git a/config/default.json b/config/default.json index 38d4e982..e7c3a7bf 100644 --- a/config/default.json +++ b/config/default.json @@ -2,5 +2,6 @@ "AV_SCAN_SCORER_REVIEW_TYPE_ID": "", "PROVISIONAL_SCORING_COMPLETED_REVIEW_TYPE_ID": "", "PAGE_SIZE": 50, - "REVIEW_OPPORTUNITY_PAGE_SIZE": 1000 + "REVIEW_OPPORTUNITY_PAGE_SIZE": 1000, + "GOOGLE_ANALYTICS_ID": "" } diff --git a/config/development.json b/config/development.json index b1519a01..95eeb428 100644 --- a/config/development.json +++ b/config/development.json @@ -1,4 +1,5 @@ { "AV_SCAN_SCORER_REVIEW_TYPE_ID": "68c5a381-c8ab-48af-92a7-7a869a4ee6c3", - "PROVISIONAL_SCORING_COMPLETED_REVIEW_TYPE_ID": "52c91e85-745f-4e62-b592-9879a2dfe9fd" + "PROVISIONAL_SCORING_COMPLETED_REVIEW_TYPE_ID": "52c91e85-745f-4e62-b592-9879a2dfe9fd", + "GOOGLE_ANALYTICS_ID": "UA-161803421-1" } diff --git a/config/production.json b/config/production.json index d2b1223d..92031113 100644 --- a/config/production.json +++ b/config/production.json @@ -1,4 +1,5 @@ { "AV_SCAN_SCORER_REVIEW_TYPE_ID": "55bbb17d-aac2-45a6-89c3-a8d102863d05", - "PROVISIONAL_SCORING_COMPLETED_REVIEW_TYPE_ID": "df51ca7d-fb0a-4147-9569-992fcf5aae48" + "PROVISIONAL_SCORING_COMPLETED_REVIEW_TYPE_ID": "df51ca7d-fb0a-4147-9569-992fcf5aae48", + "GOOGLE_ANALYTICS_ID": "UA-6340959-1" } diff --git a/package.json b/package.json index e9067a4e..c8d10a1b 100644 --- a/package.json +++ b/package.json @@ -30,7 +30,8 @@ "jest": "jest --no-cache --maxWorkers=4 --config config/jest/default.js", "lint": "npm run lint:js", "lint:js": "./node_modules/.bin/eslint --ext .js,.jsx .", - "test": "npm run lint && npm run jest" + "test": "npm run lint && npm run jest", + "rimraf": "./node_modules/rimraf/bin.js" }, "version": "0.16.0", "dependencies": { diff --git a/src/utils/tracking.js b/src/utils/tracking.js index 57bc15d8..4b764615 100644 --- a/src/utils/tracking.js +++ b/src/utils/tracking.js @@ -1,7 +1,9 @@ /* global window */ +/* global CONFIG */ import ReactGA from 'react-ga'; +const { GOOGLE_ANALYTICS_ID } = CONFIG; const TRACKING_NAME = 'tracking'; /** @@ -10,7 +12,7 @@ const TRACKING_NAME = 'tracking'; */ export const init = (userId) => { ReactGA.initialize([{ - trackingId: 'UA-161803421-1', + trackingId: GOOGLE_ANALYTICS_ID, gaOptions: { name: TRACKING_NAME, userId,