From 8b596861d59f8b523fa4de90f66caeceb84eb867 Mon Sep 17 00:00:00 2001 From: mrholek Date: Thu, 29 Jun 2023 12:58:47 +0200 Subject: [PATCH 1/5] chore: update dependencies and devDependencies MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit @coreui/chartjs ^3.1.1 → ^3.1.2 @coreui/react ^4.6.0 → ^4.8.0 @coreui/react-chartjs ^2.1.2 → ^2.1.3 @coreui/utils ^2.0.1 → ^2.0.2 core-js ^3.29.0 → ^3.31.0 eslint-config-prettier ^8.7.0 → ^8.8.0 prettier 2.8.4 → 2.8.8 react-redux ^8.0.5 → ^8.1.1 react-router-dom ^6.8.2 → ^6.14.0 sass ^1.58.3 → ^1.63.6 web-vitals ^3.1.1 → ^3.3.2 --- package.json | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/package.json b/package.json index da08efaab..d6e40d776 100644 --- a/package.json +++ b/package.json @@ -22,22 +22,22 @@ "test:debug": "react-scripts --inspect-brk test --runInBand" }, "dependencies": { - "@coreui/chartjs": "^3.1.1", + "@coreui/chartjs": "^3.1.2", "@coreui/coreui": "^4.2.6", "@coreui/icons": "^3.0.1", "@coreui/icons-react": "^2.1.0", - "@coreui/react": "^4.6.0", - "@coreui/react-chartjs": "^2.1.2", - "@coreui/utils": "^2.0.1", + "@coreui/react": "^4.9.0-rc.0", + "@coreui/react-chartjs": "^2.1.3", + "@coreui/utils": "^2.0.2", "chart.js": "^3.9.1", "classnames": "^2.3.2", - "core-js": "^3.29.0", + "core-js": "^3.31.0", "prop-types": "^15.8.1", "react": "^18.2.0", "react-app-polyfill": "^3.0.0", "react-dom": "^18.2.0", - "react-redux": "^8.0.5", - "react-router-dom": "^6.8.2", + "react-redux": "^8.1.1", + "react-router-dom": "^6.14.0", "redux": "4.2.1", "simplebar-react": "^2.4.3" }, @@ -45,12 +45,12 @@ "@testing-library/jest-dom": "^5.16.5", "@testing-library/react": "^14.0.0", "@testing-library/user-event": "^14.4.3", - "eslint-config-prettier": "^8.7.0", + "eslint-config-prettier": "^8.8.0", "eslint-plugin-prettier": "^4.2.1", - "prettier": "2.8.4", + "prettier": "2.8.8", "react-scripts": "5.0.1", - "sass": "^1.58.3", - "web-vitals": "^3.1.1" + "sass": "^1.63.6", + "web-vitals": "^3.3.2" }, "engines": { "node": ">=10", From 3ee6de47c15098c32a50857b6d146eec934b08b9 Mon Sep 17 00:00:00 2001 From: mrholek Date: Thu, 29 Jun 2023 13:07:07 +0200 Subject: [PATCH 2/5] chore: update comments --- public/index.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/public/index.html b/public/index.html index b25132580..21d293335 100644 --- a/public/index.html +++ b/public/index.html @@ -2,9 +2,9 @@ From d96983bff110aa1ca449c1dd949306d0cf01b288 Mon Sep 17 00:00:00 2001 From: mrholek Date: Thu, 29 Jun 2023 13:11:35 +0200 Subject: [PATCH 3/5] refactor: add Google Tag Manager --- public/index.html | 13 +++++++++++++ src/layout/DefaultLayout.js | 15 ++++++++++++++- 2 files changed, 27 insertions(+), 1 deletion(-) diff --git a/public/index.html b/public/index.html index 21d293335..788eed772 100644 --- a/public/index.html +++ b/public/index.html @@ -30,9 +30,22 @@ work correctly both with client-side routing and a non-root public URL. Learn how to configure a non-root public URL by running `npm run build`. --> + + +
diff --git a/src/layout/DefaultLayout.js b/src/layout/DefaultLayout.js index 43bd64432..a7f1cc689 100644 --- a/src/layout/DefaultLayout.js +++ b/src/layout/DefaultLayout.js @@ -1,7 +1,20 @@ -import React from 'react' +import React, { useEffect } from 'react' +import { useLocation } from 'react-router-dom' + import { AppContent, AppSidebar, AppFooter, AppHeader } from '../components/index' const DefaultLayout = () => { + const location = useLocation() + + useEffect(() => { + // Google Tag Manager + window.dataLayer = window.dataLayer || [] + window.dataLayer.push({ + event: 'pageview', + page_location: window.location.href, + }) + }, [location]) + return (
From 3ced89c529cd17f2908fb63d6387332f7d4baaa7 Mon Sep 17 00:00:00 2001 From: mrholek Date: Wed, 25 Oct 2023 12:52:20 +0200 Subject: [PATCH 4/5] chore: update github actions --- .github/workflows/npm.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/npm.yml b/.github/workflows/npm.yml index 27f1fd685..babbed75a 100644 --- a/.github/workflows/npm.yml +++ b/.github/workflows/npm.yml @@ -16,7 +16,7 @@ jobs: strategy: matrix: platform: [ubuntu-latest, windows-latest] - node-version: [16.x, 17.x, 18.x] + node-version: [16.x, 17.x, 18.x, 19.x, 20.x, 21.x] runs-on: ${{ matrix.platform }} steps: - name: Clone repository From a48c69820ccb7ce21f321ad7d9bcd4193681d94f Mon Sep 17 00:00:00 2001 From: mrholek Date: Wed, 25 Oct 2023 13:01:36 +0200 Subject: [PATCH 5/5] chore: update github actions --- .github/workflows/npm.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/npm.yml b/.github/workflows/npm.yml index babbed75a..bd0fef2d4 100644 --- a/.github/workflows/npm.yml +++ b/.github/workflows/npm.yml @@ -16,7 +16,7 @@ jobs: strategy: matrix: platform: [ubuntu-latest, windows-latest] - node-version: [16.x, 17.x, 18.x, 19.x, 20.x, 21.x] + node: [18, 19, 20, 21] runs-on: ${{ matrix.platform }} steps: - name: Clone repository @@ -25,7 +25,7 @@ jobs: - name: Set up Node.js uses: actions/setup-node@v3 with: - node-version: ${{ env.node-version }} + node-version: ${{ matrix.node }} - name: Install npm dependencies run: npm install