forked from JackHamer09/zksync-plus
-
Notifications
You must be signed in to change notification settings - Fork 53
/
nuxt.config.ts
97 lines (96 loc) · 2.36 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
import { portal as portalMeta } from "./data/meta";
// https://nuxt.com/docs/api/configuration/nuxt-config
export default defineNuxtConfig({
app: {
head: {
htmlAttrs: {
lang: "en",
},
link: [
{
rel: "stylesheet",
href: "https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap",
},
],
meta: [
{
property: "og:image",
content: portalMeta.previewImg.src,
},
{
property: "og:image:alt",
content: portalMeta.previewImg.alt,
},
{
property: "og:image:type",
content: "image/jpeg",
},
{
property: "og:image:width",
content: "1200",
},
{
property: "og:image:height",
content: "630",
},
],
script: [
{
src: "/config.js",
},
process.env.RUDDER_KEY
? {
hid: "Rudder-JS",
src: "https://cdn.rudderlabs.com/v1.1/rudder-analytics.min.js",
defer: true,
}
: undefined,
],
},
},
plugins: [],
modules: [
"@kevinmarrec/nuxt-pwa",
"@pinia/nuxt", // https://pinia.vuejs.org/ssr/nuxt.html
"@nuxtjs/eslint-module", // https://nuxt.com/modules/eslint
"@nuxtjs/tailwindcss", // https://nuxt.com/modules/tailwindcss
],
css: ["@/assets/css/tailwind.css", "@/assets/css/style.scss", "web3-avatar-vue/dist/style.css"],
ssr: false,
pinia: {
storesDirs: ["./store/**"],
},
pwa: {
meta: {
name: portalMeta.title,
description: portalMeta.description,
},
manifest: {
name: portalMeta.title,
short_name: "Portal",
},
},
postcss: {
plugins: {
tailwindcss: {},
autoprefixer: {},
},
},
vite: {
// Make listed envs public and accessible in the runtime
define: Object.fromEntries(
["NODE_TYPE", "WALLET_CONNECT_PROJECT_ID", "ANKR_TOKEN", "SCREENING_API_URL", "RUDDER_KEY", "DATAPLANE_URL"].map(
(key) => [`process.env.${key}`, JSON.stringify(process.env[key])]
)
),
css: {
preprocessorOptions: {
scss: {
// eslint-disable-next-line quotes
additionalData: '@use "@/assets/css/_mixins.scss" as *;',
},
},
},
},
devtools: { enabled: true },
});