You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
92 lines
2.2 KiB
92 lines
2.2 KiB
6 months ago
|
import { getEnvConfig } from './nuxt/env'
|
||
|
const envConfig = getEnvConfig()
|
||
|
export default defineNuxtConfig({
|
||
|
app: {
|
||
|
layoutTransition: { name: 'layout', mode: 'out-in' },
|
||
|
baseURL: envConfig.baseUrl,
|
||
|
head: {
|
||
|
title: '花机宝 鲜花蛋糕行业高效运营管理系统',
|
||
|
meta: [
|
||
|
{ name: 'viewport', content: 'width=device-width, initial-scale=1' },
|
||
|
{
|
||
|
hid: 'description',
|
||
|
name: 'description',
|
||
|
content: '花机宝商城',
|
||
|
},
|
||
|
],
|
||
|
link: [
|
||
|
{ rel: 'icon', type: 'image/x-icon', href: 'favicon.ico' },
|
||
|
{ rel: 'stylesheet', type: 'text/css', href: '/fonts/iconfont.css' },
|
||
|
{ rel: 'stylesheet', type: 'text/css', href: '//at.alicdn.com/t/c/font_4138656_3e69hlfaevj.css' },
|
||
|
{ rel: '', type: 'text/css', href: '//at.alicdn.com/t/c/font_4138656_3e69hlfaevj.css' },
|
||
|
],
|
||
|
},
|
||
|
},
|
||
|
ssr: false,
|
||
|
css: ['~/assets/fonts/font.css','~/assets/scss/index.scss', '~/assets/iconfont/iconfont.css', 'aos/dist/aos.css',{src: "~/utils/lib-flex.js"}], // 加载响应式模块
|
||
|
typescript: {
|
||
|
strict: true,
|
||
|
shim: false,
|
||
|
},
|
||
|
router: {
|
||
|
middleware: ['requireLogin'],
|
||
|
},
|
||
|
runtimeConfig: {
|
||
|
public: {
|
||
|
...envConfig,
|
||
|
},
|
||
|
},
|
||
|
|
||
|
// build modules
|
||
|
modules: [
|
||
|
'@vueuse/nuxt',
|
||
|
'@unocss/nuxt',
|
||
|
'@pinia/nuxt',
|
||
|
// '@pinia-plugin-persistedstate/nuxt',
|
||
|
'@element-plus/nuxt',
|
||
|
'@nuxtjs/color-mode',
|
||
|
'@fullpage/nuxt-fullpage',
|
||
|
// 'nuxt-swiper',
|
||
|
],
|
||
|
swiper: {
|
||
|
// Swiper options
|
||
|
//----------------------
|
||
|
// prefix: 'Swiper',
|
||
|
// styleLang: 'css',
|
||
|
// modules: ['navigation', 'pagination'], // all modules are imported by default
|
||
|
},
|
||
|
// vueuse
|
||
|
vueuse: {
|
||
|
ssrHandlers: true,
|
||
|
},
|
||
|
|
||
|
// colorMode
|
||
|
colorMode: {
|
||
|
classSuffix: '',
|
||
|
},
|
||
|
plugins: [{ src: '~/plugins/fetch' },
|
||
|
{src: "~/plugins/vue-swiper", ssr: false}
|
||
|
],
|
||
|
unocss: {
|
||
|
uno: true,
|
||
|
attributify: true,
|
||
|
icons: {
|
||
|
scale: 1.2,
|
||
|
},
|
||
|
},
|
||
|
vite: {
|
||
|
css: {
|
||
|
preprocessorOptions: {
|
||
|
scss: {
|
||
|
additionalData: `@use "@/assets/scss/element/index.scss" as element;`,
|
||
|
},
|
||
|
},
|
||
|
},
|
||
|
},
|
||
|
elementPlus: {
|
||
|
icon: 'ElIcon',
|
||
|
importStyle: 'scss',
|
||
|
themes: ['dark'],
|
||
|
},
|
||
|
})
|