Skip to content

Commit

Permalink
chore(docs): generate sitemap (#260)
Browse files Browse the repository at this point in the history
  • Loading branch information
hougesen authored Jun 11, 2024
1 parent ec7fb83 commit e30b45b
Show file tree
Hide file tree
Showing 4 changed files with 687 additions and 60 deletions.
90 changes: 53 additions & 37 deletions docs/nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,51 +50,25 @@ export default defineNuxtConfig({
},
},

devtools: { enabled: true },

modules: ['@nuxt/image', '@nuxt/content', '@nuxt/eslint'],

image: {
domains: ['mhouge.dk', 'hitt.mhouge.dk'],
provider: 'ipx',
presets: {
default: {
modifiers: {
format: 'webp',
quality: '80',
},
},
svg: {
modifiers: {
format: 'svg',
quality: '100',
},
},
},
},

postcss: {
plugins: {
tailwindcss: {},
autoprefixer: {},
},
},

css: ['~/assets/css/main.css'],

content: {
documentDriven: true,

experimental: {
cacheContents: true,
},
highlight: {
langs: ['http', 'sh', 'lua', 'bash', 'powershell', 'zsh', 'fish'],
theme: {
default: 'one-dark-pro',
},
langs: ['http', 'sh', 'lua', 'bash', 'powershell', 'zsh', 'fish'],
},
experimental: {
cacheContents: true,
},
},

css: ['~/assets/css/main.css'],

devtools: {
enabled: true,
},

eslint: {
checker: true,
config: {
Expand All @@ -104,4 +78,46 @@ export default defineNuxtConfig({
},
},
},

image: {
domains: ['mhouge.dk', 'hitt.mhouge.dk'],
provider: 'ipxStatic',
},

modules: ['@nuxt/image', '@nuxt/content', '@nuxt/eslint', '@nuxtjs/sitemap'],

nitro: {
minify: true,
prerender: {
crawlLinks: true,
routes: ['/', '/sitemap.xml'],
},
},

postcss: {
plugins: {
autoprefixer: {},
tailwindcss: {},
},
},

routeRules: {
'/': {
prerender: true,
},
},

site: {
indexable: true,
url: 'https://hitt.mhouge.dk',
},

sitemap: {
cacheMaxAgeSeconds: 3600,
credits: false,
discoverImages: true,
enabled: true,
},

telemetry: false,
});
1 change: 1 addition & 0 deletions docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
"devDependencies": {
"@nuxt/devtools": "^1.3.3",
"@nuxt/eslint": "^0.3.13",
"@nuxtjs/sitemap": "^5.2.0",
"@tailwindcss/typography": "^0.5.13",
"autoprefixer": "^10.4.19",
"eslint-plugin-tailwindcss": "^3.17.3",
Expand Down
Loading

0 comments on commit e30b45b

Please sign in to comment.