-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathnuxt.config.ts
174 lines (173 loc) · 4.9 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
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
import tailwindTypography from "@tailwindcss/typography";
export default defineNuxtConfig({
ssr: true,
modules: [
"@nuxt/ui",
"@nuxt/content",
"nuxt-gtag",
"@nuxtjs/seo",
"@nuxtjs/sitemap",
"@nuxtjs/web-vitals",
"@nuxt/image",
"@vueuse/motion/nuxt",
"@nuxt/eslint",
"@pinia/nuxt",
"@nuxtjs/leaflet",
],
devtools: { enabled: true },
nitro: {
plugins: ["~/server/plugins/redirects.ts"],
},
runtimeConfig: {
public: {
siteUrl: process.env.NUXT_PUBLIC_SITE_URL,
showPinnedPeoples: process.env.PUBLIC_SHOW_PINNED_PEOLPLES,
showBarometer: process.env.PUBLIC_SHOW_BAROMETER,
showScandals: process.env.PUBLIC_SHOW_SCANDALS,
brevoApiKey: process.env.BREVO_API_KEY,
brevoListId: process.env.BREVO_LIST_ID,
cmsApiUrl: process.env.CMS_API_URL,
cmsApiKey: process.env.CMS_API_KEY,
sunuElectionApiUrl: process.env.SUNU_ELECTION_API_URL,
sunuElectionApiKey: process.env.SUNU_ELECTION_API_KEY,
fbPixelId: process.env.FACEBOOK_PIXEL_ID || "",
redirects: [
{ from: "^/reports(.*)", to: "/rapport-senegal$1" },
{ from: "^/budget-etat-senegal(.*)", to: "/budget-senegal$1" },
{
from: "^/nomination-senegal/conseil-des-ministres-07-aout(.*)",
to: "/nomination-senegal$1",
},
{
from: "^/nomination-senegal/conseil-des-ministres-18-juillet(.*)",
to: "/nomination-senegal$1",
},
{
from: "^/nomination-senegal/conseil-des-ministres-31-juillet(.*)",
to: "/nomination-senegal$1",
},
],
},
},
css: ["~/assets/css/app.css"],
colorMode: {
preference: "light",
},
tailwindcss: {
config: {
plugins: [tailwindTypography],
},
},
content: {
defaultLocale: "fr",
experimental: {
search: true,
payloadExtraction: true,
renderJsonPayloads: true,
},
},
app: {
head: {
titleTemplate: "%s | Vie-Publique.sn",
title: "l'information publique au Sénégal | Vie-Publique.sn",
charset: "utf-8",
viewport: "width=device-width, initial-scale=1",
meta: [
{
name: "keywords",
content:
"République Sénégal gouvernement Diomaye Sonko journal officiel rapports OFNAC Cours des Comptes IGE ARMP CENTIF",
},
{
name: "description",
content:
"République du Sénégal, Gouvernement, nominations, journal officiel, rapports d'audit OFNAC Cours des Compte, Diomaye Faye, Ousmane SOnko",
},
// Open Graph Meta Tags
{
property: "og:title",
content: "l'information publique au Sénégal | Vie-Publique.sn",
},
{
property: "og:description",
content:
"République du Sénégal, Gouvernement Diomaye Faye et Ousmane Sonko, nominations, journal officiel, rapports d'audit OFNAC Cours des Compte",
},
{
name: "og:locale",
content: "fr_FR",
},
{
property: "og:image",
content: "https://vie-publique.sn/images/share-linkedin.png",
},
{
property: "og:image:type",
content: "image/png",
},
{
property: "og:image:width",
content: "1353",
},
{
property: "og:image:height",
content: "1082",
},
{
property: "og:url",
content: "https://vie-publique.sn",
},
{
property: "og:type",
content: "website",
},
{
property: "og:site_name",
content: "l'information publique au Sénégal | Vie-Publique.sn",
},
// Twitter Card Meta Tags
{
name: "twitter:title",
content: "l'information publique au Sénégal | Vie-Publique.sn",
},
{
name: "twitter:description",
content:
"Gouvernement du Sénégal, nominations de Diomaye et Sonko, journal officiel, rapports d'audit OFNAC Cours des Comptes",
},
{ name: "twitter:card", content: "summary_large_image" },
{ name: "twitter:image", content: "/images/share-linkedin.png" },
],
script: [
{
type: "module",
src: "//instant.page/5.1.1",
integrity:
"sha384-MWfCL6g1OTGsbSwfuMHc8+8J2u71/LA8dzlIN3ycajckxuZZmF+DNjdm7O6H3PSq",
},
],
},
},
site: {
defaultLocale: "fr",
},
gtag: {
enabled: !!process.env.GTAG_ID,
id: process.env.GTAG_ID,
},
webVitals: {
provider: "ga",
disabled: !process.env.GTAG_ID,
ga: { id: process.env.GTAG_ID },
},
sitemap: {
sources: ["/api/__sitemap__/urls"],
},
image: {
directus: {
// This URL needs to include the final `assets/` directory
baseURL: process.env.CMS_API_URL_ASSETS,
},
},
compatibilityDate: "2024-09-08",
});