From b8991da4fa7e1d67fd0168029eabbff020946efd Mon Sep 17 00:00:00 2001 From: John Darragh Date: Mon, 30 Nov 2020 12:35:47 -0800 Subject: [PATCH 1/4] Google Analytics, Take 1 --- client/.eslintrc.json | 10 +- client/public/index.html | 14 ++ client/src/App.js | 14 +- client/src/AppWrapper.js | 130 +++++++++--------- client/src/components/Authorization/Login.js | 4 +- client/src/components/NavBar.js | 2 +- .../ProjectWizard/TdmCalculationWizard.js | 15 +- .../src/components/Projects/ProjectsPage.js | 6 +- .../src/components/TdmCalculationContainer.js | 10 +- client/src/contexts/RequiredFieldContext.js | 5 - client/src/hooks/useTracking.js | 73 +++++----- 11 files changed, 149 insertions(+), 134 deletions(-) delete mode 100644 client/src/contexts/RequiredFieldContext.js diff --git a/client/.eslintrc.json b/client/.eslintrc.json index 7178b6de..c0dedbd1 100644 --- a/client/.eslintrc.json +++ b/client/.eslintrc.json @@ -5,11 +5,16 @@ "es6": true, "jest/globals": true }, + "globals": { + "process": true + }, "extends": [ "prettier", "eslint:recommended", "plugin:react/recommended", - "plugin:jest/recommended" + "plugin:jest/recommended", + "plugin:prettier/recommended", + "plugin:react-hooks/recommended" ], "parserOptions": { "ecmaFeatures": { @@ -18,8 +23,9 @@ "ecmaVersion": 2018, "sourceType": "module" }, - "plugins": ["react", "jest"], + "plugins": ["react", "jest", "prettier"], "rules": { + "prettier/prettier": "error", "no-console": ["warn", { "allow": ["error"] }], "no-alert": "error" }, diff --git a/client/public/index.html b/client/public/index.html index 8f1af29f..5890e733 100644 --- a/client/public/index.html +++ b/client/public/index.html @@ -25,6 +25,20 @@ href="https://fonts.googleapis.com/css2?family=Oswald:wght@700&display=swap" rel="stylesheet" /> + + +