forked from yangjiakai/lux-ui-nuxt
-
Notifications
You must be signed in to change notification settings - Fork 0
/
nuxt.config.ts
114 lines (110 loc) · 2.55 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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
import { createResolver } from "@nuxt/kit";
import vuetify, { transformAssetUrls } from "vite-plugin-vuetify";
const { resolve } = createResolver(import.meta.url);
// PWA Config
const title = "Vuetify 3 + Nuxt 3 Awesome Admin";
const shortTitle = "Lux Admin";
const description = "Lux-Admin,Awesome Nuxt3-Vuetify3 Admin";
const image =
"https://github.com/yangjiakai/lux-nuxt3/blob/main/assets/images/banner.png";
const url = "https://lux-vuetify3-nuxt3.netlify.app/";
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
ssr: true,
devtools: { enabled: true },
css: ["@/assets/scss/main.scss"],
postcss: {
plugins: {
tailwindcss: {},
autoprefixer: {},
},
},
typescript: { shim: false },
build: { transpile: ["vuetify"] },
sourcemap: { server: false, client: false },
routeRules: {
"/**": { ssr: false },
},
modules: [
"@pinia/nuxt",
"@pinia-plugin-persistedstate/nuxt",
async (options, nuxt) => {
nuxt.hooks.hook("vite:extendConfig", (config) => {
config.plugins ||= [];
config.plugins.push(
vuetify({
styles: { configFile: resolve("/assets/scss/variables.scss") },
})
);
});
},
[
"@nuxtjs/google-fonts",
{
families: {
Quicksand: [500],
Inter: [400, 700],
"Josefin+Sans": true,
Lato: [100, 300],
Raleway: {
wght: [100, 400],
ital: [100],
},
},
},
],
],
vite: {
vue: {
template: {
transformAssetUrls,
},
},
},
app: {
head: {
title: "Lux-Nuxt3",
meta: [
{ name: "description", content: description },
{
property: "og:url",
content: url,
},
{
property: "og:image:secure_url",
content: image,
},
{
property: "og:title",
content: title,
},
{
property: "og:description",
content: description,
},
{
property: "og:image",
content: image,
},
//Twitter
{ name: "twitter:card", content: "summary_large_image" },
{
name: "twitter:url",
content: url,
},
{
name: "twitter:title",
content: title,
},
{
name: "twitter:description",
content: description,
},
{
name: "twitter:image",
content: image,
},
],
},
},
});