diff --git a/.history/.env_20220613182216.local b/.history/.env_20220613182216.local
deleted file mode 100644
index e69de29..0000000
diff --git a/.history/.env_20220613182253.local b/.history/.env_20220613182253.local
deleted file mode 100644
index 61ab8a7..0000000
--- a/.history/.env_20220613182253.local
+++ /dev/null
@@ -1,12 +0,0 @@
-// .env.local
-
-USER_="crapshr6_robotop"
-HOST="crapshr6.beget.tech"
-DATABASE="crapshr6_pizza"
-PASSWORD="M2PJD&wG"
-
-MAILSERVER="smtp.beget.com"
-MAILNAME="service@vsst.su"
-MAILPASS = "&ekS0NPD"
-
-SITE="http://localhost:3000/api/"
\ No newline at end of file
diff --git a/.history/.env_20220613182355.local b/.history/.env_20220613182355.local
deleted file mode 100644
index e1270af..0000000
--- a/.history/.env_20220613182355.local
+++ /dev/null
@@ -1,12 +0,0 @@
-// .env.local
-
-USER_="crapshr6_robotop"
-HOST="crapshr6.beget.tech"
-DATABASE="crapshr6_robotop"
-PASSWORD="5NC*%v0v"
-
-MAILSERVER="smtp.beget.com"
-MAILNAME="service@vsst.su"
-MAILPASS = "&ekS0NPD"
-
-SITE="http://localhost:3000/api/"
\ No newline at end of file
diff --git a/.history/.env_20220613182359.local b/.history/.env_20220613182359.local
deleted file mode 100644
index e1270af..0000000
--- a/.history/.env_20220613182359.local
+++ /dev/null
@@ -1,12 +0,0 @@
-// .env.local
-
-USER_="crapshr6_robotop"
-HOST="crapshr6.beget.tech"
-DATABASE="crapshr6_robotop"
-PASSWORD="5NC*%v0v"
-
-MAILSERVER="smtp.beget.com"
-MAILNAME="service@vsst.su"
-MAILPASS = "&ekS0NPD"
-
-SITE="http://localhost:3000/api/"
\ No newline at end of file
diff --git a/.history/.env_20220613183941.local b/.history/.env_20220613183941.local
deleted file mode 100644
index a1d837d..0000000
--- a/.history/.env_20220613183941.local
+++ /dev/null
@@ -1,12 +0,0 @@
-// .env.local
-
-USER_="crapshr6_robotop"
-HOST="crapshr6.beget.tech"
-DATABASE="crapshr6_robotop"
-PASSWORD="sJ9&alNk"
-
-MAILSERVER="smtp.beget.com"
-MAILNAME="service@vsst.su"
-MAILPASS = "&ekS0NPD"
-
-SITE="http://localhost:3000/api/"
\ No newline at end of file
diff --git a/components/Head.tsx b/components/Head.tsx
index 09fe080..8b69669 100644
--- a/components/Head.tsx
+++ b/components/Head.tsx
@@ -3,6 +3,10 @@ import { useRouter } from 'next/router';
import React from 'react';
import { MetaProps } from '../types/layout';
+export type WithYandexMetrikaProps = {
+ children: React.ReactNode;
+}
+
export const WEBSITE_HOST_URL = 'https://robotop.krasnikov.pro/';
const Head = ({ customMeta }: { customMeta?: MetaProps }): JSX.Element => {
diff --git a/package-lock.json b/package-lock.json
index b7dbb62..c666f5f 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -27,6 +27,7 @@
"react-hook-form": "^7.33.1",
"react-redux": "^8.0.2",
"react-toastify": "^9.0.5",
+ "react-yandex-metrika": "^2.6.0",
"rehype-autolink-headings": "^6.1.1",
"rehype-slug": "^5.0.1",
"remark-code-titles": "^0.1.2",
@@ -9907,7 +9908,6 @@
"version": "4.1.1",
"resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz",
"integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==",
- "dev": true,
"engines": {
"node": ">=0.10.0"
}
@@ -10447,7 +10447,6 @@
"version": "15.8.1",
"resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.8.1.tgz",
"integrity": "sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg==",
- "dev": true,
"dependencies": {
"loose-envify": "^1.4.0",
"object-assign": "^4.1.1",
@@ -10457,8 +10456,7 @@
"node_modules/prop-types/node_modules/react-is": {
"version": "16.13.1",
"resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz",
- "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==",
- "dev": true
+ "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ=="
},
"node_modules/property-information": {
"version": "6.1.1",
@@ -10629,6 +10627,15 @@
"react-dom": ">=16"
}
},
+ "node_modules/react-yandex-metrika": {
+ "version": "2.6.0",
+ "resolved": "https://registry.npmjs.org/react-yandex-metrika/-/react-yandex-metrika-2.6.0.tgz",
+ "integrity": "sha512-8K4wExsNZtY3DTxh1G8a+zWH9Pg8fw23MJcoJ4I/562qrHRnh7L5nteq3lnNL58dnNQbuuHIRoGgMjIo+r1GjA==",
+ "peerDependencies": {
+ "prop-types": "*",
+ "react": "*"
+ }
+ },
"node_modules/read-cache": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/read-cache/-/read-cache-1.0.0.tgz",
@@ -12048,9 +12055,9 @@
}
},
"node_modules/terser": {
- "version": "5.14.1",
- "resolved": "https://registry.npmjs.org/terser/-/terser-5.14.1.tgz",
- "integrity": "sha512-+ahUAE+iheqBTDxXhTisdA8hgvbEG1hHOQ9xmNjeUJSoi6DU/gMrKNcfZjHkyY6Alnuyc+ikYJaxxfHkT3+WuQ==",
+ "version": "5.14.2",
+ "resolved": "https://registry.npmjs.org/terser/-/terser-5.14.2.tgz",
+ "integrity": "sha512-oL0rGeM/WFQCUd0y2QrWxYnq7tfSuKBiqTjRPWrRgB46WD/kiwHwF8T23z78H6Q6kGCuuHcPB+KULHRdxvVGQA==",
"peer": true,
"dependencies": {
"@jridgewell/source-map": "^0.3.2",
@@ -20072,8 +20079,7 @@
"object-assign": {
"version": "4.1.1",
"resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz",
- "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==",
- "dev": true
+ "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg=="
},
"object-hash": {
"version": "3.0.0",
@@ -20424,7 +20430,6 @@
"version": "15.8.1",
"resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.8.1.tgz",
"integrity": "sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg==",
- "dev": true,
"requires": {
"loose-envify": "^1.4.0",
"object-assign": "^4.1.1",
@@ -20434,8 +20439,7 @@
"react-is": {
"version": "16.13.1",
"resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz",
- "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==",
- "dev": true
+ "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ=="
}
}
},
@@ -20536,6 +20540,12 @@
"clsx": "^1.1.1"
}
},
+ "react-yandex-metrika": {
+ "version": "2.6.0",
+ "resolved": "https://registry.npmjs.org/react-yandex-metrika/-/react-yandex-metrika-2.6.0.tgz",
+ "integrity": "sha512-8K4wExsNZtY3DTxh1G8a+zWH9Pg8fw23MJcoJ4I/562qrHRnh7L5nteq3lnNL58dnNQbuuHIRoGgMjIo+r1GjA==",
+ "requires": {}
+ },
"read-cache": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/read-cache/-/read-cache-1.0.0.tgz",
@@ -21546,9 +21556,9 @@
}
},
"terser": {
- "version": "5.14.1",
- "resolved": "https://registry.npmjs.org/terser/-/terser-5.14.1.tgz",
- "integrity": "sha512-+ahUAE+iheqBTDxXhTisdA8hgvbEG1hHOQ9xmNjeUJSoi6DU/gMrKNcfZjHkyY6Alnuyc+ikYJaxxfHkT3+WuQ==",
+ "version": "5.14.2",
+ "resolved": "https://registry.npmjs.org/terser/-/terser-5.14.2.tgz",
+ "integrity": "sha512-oL0rGeM/WFQCUd0y2QrWxYnq7tfSuKBiqTjRPWrRgB46WD/kiwHwF8T23z78H6Q6kGCuuHcPB+KULHRdxvVGQA==",
"peer": true,
"requires": {
"@jridgewell/source-map": "^0.3.2",
diff --git a/package.json b/package.json
index 442eede..97ac6bf 100644
--- a/package.json
+++ b/package.json
@@ -43,6 +43,7 @@
"react-hook-form": "^7.33.1",
"react-redux": "^8.0.2",
"react-toastify": "^9.0.5",
+ "react-yandex-metrika": "^2.6.0",
"rehype-autolink-headings": "^6.1.1",
"rehype-slug": "^5.0.1",
"remark-code-titles": "^0.1.2",
diff --git a/pages/_app.tsx b/pages/_app.tsx
index f1ceb3a..60ef39b 100644
--- a/pages/_app.tsx
+++ b/pages/_app.tsx
@@ -7,11 +7,11 @@ import { store } from '../redux/store';
const MyApp = ({ Component, pageProps }: AppProps): JSX.Element => {
return (
-