CloudProxyPro/node_modules/.cache/jiti/web7-nuxt.config.026d0a3d.mjs
2025-09-05 14:59:21 +08:00

73 lines
1.6 KiB
JavaScript

"use strict";Object.defineProperty(exports, "__esModule", { value: true });exports.default = void 0;var _default = exports.default = defineNuxtConfig({
devtools: { enabled: true },
modules: [
'@nuxtjs/tailwindcss',
'@nuxtjs/i18n',
'@nuxt/content',
'@nuxtjs/sitemap',
'@nuxtjs/robots'],
// SSG配置
nitro: {
prerender: {
routes: ['/sitemap.xml']
}
},
// 国际化配置
i18n: {
locales: [
{ code: 'en', name: 'English', file: 'en.json' },
{ code: 'zh', name: '简体中文', file: 'zh.json' },
{ code: 'zh-hant', name: '繁體中文', file: 'zh-hant.json' }],
defaultLocale: 'en',
strategy: 'prefix_except_default',
lazy: true,
langDir: 'locales/',
detectBrowserLanguage: {
useCookie: true,
cookieKey: 'i18n_redirected',
redirectOn: 'root'
}
},
// 站点地图配置
sitemap: {
hostname: 'https://cloudproxy-pro.com',
gzip: true,
routes: async () => {
const { $content } = require('@nuxt/content');
const articles = await $content('').fetch();
return articles.map((article) => `/blog/${article.slug}`);
}
},
// robots.txt配置
robots: {
UserAgent: '*',
Disallow: '/admin',
Sitemap: 'https://cloudproxy-pro.com/sitemap.xml'
},
// SEO配置
app: {
head: {
htmlAttrs: {
lang: 'en'
},
link: [
{ rel: 'icon', type: 'image/x-icon', href: '/favicon.ico' }],
script: [
{
id: 'chatway',
async: true,
src: 'https://cdn.chatway.app/widget.js?id=FgIgGSxRD2i8'
}]
}
}
}); /* v9-40d942f72af6658b */