export default defineNuxtConfig({
  //taget: "static",
  ssr: true,
  app: {
    head: {
      title: '乡村网',
      meta: [
        { name: 'description', content: '乡村网' },
        { name: 'keywords', content: '乡村网' },
      ],
    },
  },
  compatibilityDate: '2025-02-28',
  devtools: { enabled: true },
  module: [
    '@nuxtjs/style-resources',
    '@element-plus/nuxt',
    "@gauseen/nuxt-proxy",
    '@pinia/nuxt',
  ],
  css: [
    '~/assets/css/global.css',
    '~/assets/css/font.css',
    'element-plus/dist/index.css',
    'element-plus/theme-chalk/display.css'
  ],
  build: {
    publicPath: '/'
  },
  nitro: {
    devServer: {
      port:3000, // 指定生产服务器的端口
    }
  },
  plugins: [
    '@/plugins/element-plus',
    {
      src: '@/plugins/request',
      mode: 'client'
    }
  ],
  server: {
    port: process.env.PORT, // 使用环境变量或默认的3000端口
    host: '0.0.0.0' // 允许外部访问
  }
})