Skip to content

Commit

Permalink
Merge pull request #60 from eksqtr/development
Browse files Browse the repository at this point in the history
Added sitemap xml and robotext for SEO thingy
  • Loading branch information
eksqtr authored Aug 29, 2024
2 parents b0da141 + 4b9b5c2 commit afae3f3
Show file tree
Hide file tree
Showing 6 changed files with 81 additions and 1 deletion.
15 changes: 15 additions & 0 deletions next-sitemap.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
/** @type {import('next-sitemap').IConfig} */
module.exports = {
siteUrl: process.env.APP_URL || 'https://eubiejay.dev', // Replace with your site's URL
generateRobotsTxt: true, // generate robotext
sitemapSize: 7000,
changefreq: 'daily',
priority: 0.7,
// exclude: ['/admin/*'], // enable this in the future incase we want to exclude something
robotsTxtOptions: {
policies: [
{ userAgent: '*', allow: '/' },
{ userAgent: 'Googlebot', allow: '/' },
],
},
};
43 changes: 43 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"private": true,
"scripts": {
"dev": "next dev",
"build": "next build",
"build": "next build && next-sitemap",
"start": "next start",
"lint": "next lint"
},
Expand All @@ -26,6 +26,7 @@
"autoprefixer": "^10.4.20",
"eslint": "^8",
"eslint-config-next": "14.2.5",
"next-sitemap": "^4.2.3",
"postcss": "^8.4.41",
"tailwindcss": "^3.4.10",
"typescript": "^5"
Expand Down
13 changes: 13 additions & 0 deletions public/robots.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# *
User-agent: *
Allow: /

# Googlebot
User-agent: Googlebot
Allow: /

# Host
Host: https://eubiejay.dev

# Sitemaps
Sitemap: https://eubiejay.dev/sitemap.xml
4 changes: 4 additions & 0 deletions public/sitemap-0.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:news="http://www.google.com/schemas/sitemap-news/0.9" xmlns:xhtml="http://www.w3.org/1999/xhtml" xmlns:mobile="http://www.google.com/schemas/sitemap-mobile/1.0" xmlns:image="http://www.google.com/schemas/sitemap-image/1.1" xmlns:video="http://www.google.com/schemas/sitemap-video/1.1">
<url><loc>https://eubiejay.dev</loc><lastmod>2024-08-29T18:04:00.376Z</lastmod><changefreq>daily</changefreq><priority>0.7</priority></url>
</urlset>
4 changes: 4 additions & 0 deletions public/sitemap.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="UTF-8"?>
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
<sitemap><loc>https://eubiejay.dev/sitemap-0.xml</loc></sitemap>
</sitemapindex>

0 comments on commit afae3f3

Please sign in to comment.