From 44e6c354bfaddf45339f4299f5c42ad2faa537dc Mon Sep 17 00:00:00 2001
From: Shreyas <69378056+shreyaspranav@users.noreply.github.com>
Date: Sun, 27 Oct 2024 14:03:50 +0530
Subject: [PATCH] Fixed the sitemap
---
docs/.vitepress/config.js | 35 ++++++++++++++++++++++++++++++++++-
docs/sitemap.xml | 23 -----------------------
2 files changed, 34 insertions(+), 24 deletions(-)
delete mode 100644 docs/sitemap.xml
diff --git a/docs/.vitepress/config.js b/docs/.vitepress/config.js
index b2f2bb1..abc85be 100644
--- a/docs/.vitepress/config.js
+++ b/docs/.vitepress/config.js
@@ -1,3 +1,6 @@
+import fs from 'fs';
+import path from 'path';
+
export default {
base: '/XenodeDevDocs/',
@@ -24,5 +27,35 @@ export default {
name: 'google-site-verification',
content: 'rk5w0mlpKvSpex5z5XJ4lhOn2nVFHLZPso7G8XzMh5M'
}]
- ]
+ ],
+
+ buildEnd() {
+ // Define the sitemap content
+ const sitemapContent = `
+
+
+ https://xenodestudio.github.io/XenodeDevDocs/
+ ${new Date().toISOString()}
+ daily
+ 1.0
+
+
+
+ https://xenodestudio.github.io/contributing
+ ${new Date().toISOString()}
+ weekly
+ 0.8
+
+
+
+ https://xenodestudio.github.io/code_of_conduct
+ ${new Date().toISOString()}
+ weekly
+ 0.8
+
+ `;
+
+ // Write the sitemap to the dist directory
+ fs.writeFileSync(path.resolve(__dirname, 'dist/sitemap.xml'), sitemapContent);
+ }
}
\ No newline at end of file
diff --git a/docs/sitemap.xml b/docs/sitemap.xml
deleted file mode 100644
index 62cc6f7..0000000
--- a/docs/sitemap.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-
-
-
- https://xenodestudio.github.io/XenodeDevDocs/
- 2024-10-01
- daily
- 1.0
-
-
-
- https://xenodestudio.github.io/contributing
- 2024-10-01
- weekly
- 0.8
-
-
-
- https://xenodestudio.github.io/code_of_conduct
- 2024-10-01
- weekly
- 0.8
-
-
\ No newline at end of file