-
Notifications
You must be signed in to change notification settings - Fork 82
/
nuxt.config.ts
57 lines (56 loc) · 1.21 KB
/
nuxt.config.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
// import { defineNuxtConfig } from 'nuxt'
// https://v3.nuxtjs.org/api/configuration/nuxt.config
export default defineNuxtConfig({
app: {
head: {
titleTemplate: "%s - 固定标题",
title: "帝莎编程",
charset: "utf-8",
htmlAttrs: {
lang: "zh-cn",
},
meta: [
{ name: "description", content: "帝莎编程描述" },
{ name: "keywords", content: "帝莎编程关键词" },
],
script: [
// { src:"http://xxx.js" }
],
link: [
// { rel:"stylesheet",href:"http://xxx.css" }
],
},
},
css: [
"@/assets/main.css",
],
modules: [
"nuxt-windicss",
],
build: {
transpile: process.env.NODE_ENV === "production"
? [
"naive-ui",
"vueuc",
"@css-render/vue3-ssr",
"@juggle/resize-observer",
]
: ["@juggle/resize-observer"],
},
vite: {
optimizeDeps: {
include: process.env.NODE_ENV === "development"
? ["naive-ui", "vueuc", "date-fns-tz/esm/formatInTimeZone"]
: [],
},
},
imports: {
dirs: ["apis"],
},
nitro: {
// 缩小捆绑包
minify: true,
// 关闭源映射生成
sourceMap: false,
},
});