From 61afce7ba54cd32e3db4eb6a8ad18ff16aea02fc Mon Sep 17 00:00:00 2001 From: adity1raut Date: Mon, 17 Nov 2025 16:15:05 +0530 Subject: [PATCH] Update The Tracking ID Signed-off-by: adity1raut --- .env.example | 1 + .gitignore | 3 ++- docusaurus.config.js | 14 ++++++-------- package.json | 1 + yarn.lock | 30 ++++++++++++++++++++++-------- 5 files changed, 32 insertions(+), 17 deletions(-) create mode 100644 .env.example diff --git a/.env.example b/.env.example new file mode 100644 index 00000000..7f8c8db9 --- /dev/null +++ b/.env.example @@ -0,0 +1 @@ +GA_TRACKING_ID = "G-854W8PEZ1Z" \ No newline at end of file diff --git a/.gitignore b/.gitignore index 2fa3effc..a4edd277 100644 --- a/.gitignore +++ b/.gitignore @@ -10,6 +10,7 @@ # Misc .DS_Store +.env .env.local .env.development.local .env.test.local @@ -22,4 +23,4 @@ yarn-error.log* # Vscode files .vscode -package-lock.json \ No newline at end of file +package-lock.json diff --git a/docusaurus.config.js b/docusaurus.config.js index 3c5a39bd..277cd311 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -1,6 +1,9 @@ // @ts-check // `@type` JSDoc annotations allow editor autocompletion and type checking +import dotenv from "dotenv"; +dotenv.config(); + import { themes as prismThemes } from "prism-react-renderer"; /** @type {import('@docusaurus/types').Config} */ @@ -12,7 +15,6 @@ const config = { url: "https://kmesh.net", // Set the // pathname under which your site is served - // For GitHub pages deployment, it is often '//' baseUrl: "/", onBrokenLinks: "throw", @@ -44,7 +46,7 @@ const config = { showLastUpdateTime: true, }, gtag: { - trackingID: "G-854W8PEZ1Z", + trackingID: process.env.GA_TRACKING_ID, anonymizeIP: true, }, blog: { @@ -53,10 +55,7 @@ const config = { type: ["rss", "atom"], xslt: true, }, - // Please change this to your repo. - // Remove this to remove the "edit this page" links. editUrl: "https://github.com/kmesh-net/website/blob/main", - // Useful options to enforce blogging best practices onInlineTags: "warn", onInlineAuthors: "warn", onUntruncatedBlogPosts: "warn", @@ -71,7 +70,6 @@ const config = { themeConfig: /** @type {import('@docusaurus/preset-classic').ThemeConfig} */ ({ - // Replace with your project's social card docs: { sidebar: { hideable: true, @@ -152,11 +150,11 @@ const config = { [ "docusaurus-lunr-search", { - languages: ["en",'zh'], + languages: ["en", "zh"], indexDocs: true, indexBlog: true, indexPages: false, - } + }, ], ], }; diff --git a/package.json b/package.json index 08d4e05a..bd5e4dd4 100644 --- a/package.json +++ b/package.json @@ -24,6 +24,7 @@ "clsx": "^2.0.0", "docusaurus-lunr-search": "^3.6.0", "docusaurus-plugin-sass": "^0.2.6", + "dotenv": "^17.2.3", "plugin-image-zoom": "flexanalytics/plugin-image-zoom", "prism-react-renderer": "^2.3.0", "react": "^19.0.0", diff --git a/yarn.lock b/yarn.lock index 71e8cc3c..1a86e1bb 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2276,10 +2276,15 @@ dependencies: "@types/mdx" "^2.0.0" -"@node-rs/jieba-darwin-arm64@2.0.1": +"@node-rs/jieba-linux-x64-gnu@2.0.1": version "2.0.1" - resolved "https://registry.npmjs.org/@node-rs/jieba-darwin-arm64/-/jieba-darwin-arm64-2.0.1.tgz" - integrity sha512-10+nwGQ6KzXXJlIL/sELA6Fi6m7eJ7xJksBiKuw1kxKUgaJwtVfAG0iqRF+NRQv0Sdq7r3k5ew9K9y0+IYaEcA== + resolved "https://registry.npmjs.org/@node-rs/jieba-linux-x64-gnu/-/jieba-linux-x64-gnu-2.0.1.tgz" + integrity sha512-sq3J6L2ANTE25I9eVFq/nb57OtXcvUIeUD1CTKJxwgTKIVmcB2LyOZpWf20AjHRUfbMER9Klqg5dgyyO+Six+w== + +"@node-rs/jieba-linux-x64-musl@2.0.1": + version "2.0.1" + resolved "https://registry.npmjs.org/@node-rs/jieba-linux-x64-musl/-/jieba-linux-x64-musl-2.0.1.tgz" + integrity sha512-0zfP9Qy68yEXrhBFknfhF6WUJDPU/8eRuyIrkMGdMjfRpxhpSbr2fMfnsqhOQLvhuK4w3iDFvTy4t5d0s6JKMA== "@node-rs/jieba@^2.0.1": version "2.0.1" @@ -2322,10 +2327,15 @@ "@nodelib/fs.scandir" "2.1.5" fastq "^1.6.0" -"@parcel/watcher-darwin-arm64@2.5.1": +"@parcel/watcher-linux-x64-glibc@2.5.1": version "2.5.1" - resolved "https://registry.npmjs.org/@parcel/watcher-darwin-arm64/-/watcher-darwin-arm64-2.5.1.tgz" - integrity sha512-eAzPv5osDmZyBhou8PoF4i6RQXAfeKL9tjb3QzYuccXFMQU0ruIc/POh30ePnaOyD1UXdlKguHBmsTs53tVoPw== + resolved "https://registry.npmjs.org/@parcel/watcher-linux-x64-glibc/-/watcher-linux-x64-glibc-2.5.1.tgz" + integrity sha512-GcESn8NZySmfwlTsIur+49yDqSny2IhPeZfXunQi48DMugKeZ7uy1FX83pO0X22sHntJ4Ub+9k34XQCX+oHt2A== + +"@parcel/watcher-linux-x64-musl@2.5.1": + version "2.5.1" + resolved "https://registry.npmjs.org/@parcel/watcher-linux-x64-musl/-/watcher-linux-x64-musl-2.5.1.tgz" + integrity sha512-n0E2EQbatQ3bXhcH2D1XIAANAcTZkQICBPVaxMeaCVBtOpBZpWJuf7LwyWPSBDITb7In8mqQgJ7gH8CILCURXg== "@parcel/watcher@^2.4.1": version "2.5.1" @@ -4356,6 +4366,11 @@ dot-prop@^6.0.1: dependencies: is-obj "^2.0.0" +dotenv@^17.2.3: + version "17.2.3" + resolved "https://registry.npmjs.org/dotenv/-/dotenv-17.2.3.tgz" + integrity sha512-JVUnt+DUIzu87TABbhPmNfVdBDt18BLOWjMUFJMSi/Qqg7NTYtabbvSNJGOJ7afbRuv9D/lngizHtP7QyLQ+9w== + dunder-proto@^1.0.1: version "1.0.1" resolved "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz" @@ -7515,8 +7530,7 @@ pkg-up@^3.1.0: plugin-image-zoom@flexanalytics/plugin-image-zoom: version "1.1.0" - resolved "https://codeload.github.com/flexanalytics/plugin-image-zoom/tar.gz/8e1b866c79ed6d42cefc4c52f851f1dfd1d0c7de" - integrity sha512-y/KQYx2qGrnMwB0zPxxN3g2teitLlHjGFJDoepfjJg2cC1AB5qCC9Bzp5YsNGQb2+Vw0Nd4O32b8FQGTgFSrVw== + resolved "git+ssh://git@github.com/flexanalytics/plugin-image-zoom.git#8e1b866c79ed6d42cefc4c52f851f1dfd1d0c7de" dependencies: medium-zoom "^1.0.8"