-
Notifications
You must be signed in to change notification settings - Fork 3
/
vue.config.js
178 lines (177 loc) · 10.3 KB
/
vue.config.js
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
175
176
177
178
const zlib = require('zlib');
const PrerenderSPAPlugin = require('prerender-spa-plugin');
const path = require('path');
module.exports = {
devServer: {
host: 'parkspot.localhost',
},
productionSourceMap: false, // Setting this to false can speed up production builds if you don't need source maps for production.
configureWebpack: (config) => {
if (process.env.NODE_ENV === 'production') {
return {
devtool: 'source-map',
// ! pre-render code
plugins: [
new PrerenderSPAPlugin({
// Absolute path to compiled SPA
staticDir: path.resolve(__dirname, './dist'),
// List of routes to prerender
routes: [
'/about/',
'/contact/',
'/features/',
'/faq/',
'/blog/',
'/blog/eliminating-traffic-jams-in-india/',
'/blog/parking-challenges-in-office-area/',
'/blog/no-parking/',
'/bangalore/parking-near-btm/',
'/bangalore/parking-near-adugodi/',
'/bangalore/parking-near-ashoknagar/',
'/bangalore/parking-near-banashankari/',
'/bangalore/parking-near-bharathinagar/',
'/bangalore/parking-near-bommanahalli/',
'/bangalore/parking-near-byappanahalli/',
'/bangalore/parking-near-byatarayanapura/',
'/bangalore/parking-near-chandra-layout/',
'/bangalore/parking-near-commercial-street/',
'/bangalore/parking-near-devanahalli/',
'/bangalore/parking-near-electronic-city/',
'/bangalore/parking-near-gangammanagudi/',
'/bangalore/parking-near-girinagar/',
'/bangalore/parking-near-hsr-layout/',
'/bangalore/parking-near-hennur/',
'/bangalore/parking-near-hulimavu/',
'/bangalore/parking-near-indiranagar/',
'/bangalore/parking-near-jp-nagar/',
'/bangalore/parking-near-jalahalli/',
'/bangalore/parking-near-jayanagar/',
'/bangalore/parking-near-jeevan-bima-nagar/',
'/bangalore/parking-near-kadugodi/',
'/bangalore/parking-near-kalasipalya/',
'/bangalore/parking-near-kempegowda-international-airport/',
'/bangalore/parking-near-kengeri/',
'/bangalore/parking-near-kodigehalli/',
'/bangalore/parking-near-konanakunte/',
'/bangalore/parking-near-koramangala/',
'/bangalore/parking-near-mahadevapura/',
'/bangalore/parking-near-malleshwarm/',
'/bangalore/parking-near-marathahalli/',
'/bangalore/parking-near-sadashivanagar/',
'/bangalore/parking-near-srirampuram/',
'/bangalore/parking-near-subramanyapura/',
'/bangalore/parking-near-vijayanagar/',
'/bangalore/parking-near-whitefield/',
'/bangalore/parking-near-yelahanka/',
'/bangalore/parking-near-kengeri-gate/',
'/bangalore/parking-near-chickpet/',
'/bangalore/parking-near-yalahanka/',
'/hyderabad/parking-near-hyderabad/',
// '/bangalore/parking-near-chikkajala/',
// '/bangalore/parking-near-city-market/',
// '/bangalore/parking-near-high-ground/',
// '/bangalore/parking-near-jc-nagar/',
// '/bangalore/parking-near-kamakshipalya/',
// '/bangalore/parking-near-kempapura-agrahara/',
// '/bangalore/parking-near-mico-layout/',
// '/bangalore/parking-near-Subramanyanagar',
// '/bangalore/parking-near-Halasoor',
// '/bangalore/parking-near-Halasoor-Gate',
// '/bangalore/parking-near-HAL',
// '/bangalore/parking-near-Amrutha-Halli',
// '/bangalore/parking-near-Annapoorneshwari-Nagar',
// '/bangalore/parking-near-Bagalgunte',
// '/bangalore/parking-near-Banasawadi',
// '/bangalore/parking-near-Bande-Palya',
// '/bangalore/parking-near-Basavanagudi',
// '/bangalore/parking-near-Basavanagudi-women-PS',
// '/bangalore/parking-near-Basaveshwara-Nagar',
// '/bangalore/parking-near-Beguru',
// '/bangalore/parking-near-Bellanduru',
// '/bangalore/parking-near-Bhagalur',
// '/bangalore/parking-near-CK-Achukattu',
// '/bangalore/parking-near-Chamarajapet',
// '/bangalore/parking-near-CottenPet',
// '/bangalore/parking-near-Cubbon-Park',
// '/bangalore/parking-near-DJ-Halli',
// '/bangalore/parking-near-Hanumanthanagar',
// '/bangalore/parking-near-Hebbal',
// '/bangalore/parking-near-Jagajeevanram-Nagar',
// '/bangalore/parking-near-Jnanabharathi',
// '/bangalore/parking-near-KG-Halli',
// '/bangalore/parking-near-KG-Nagar',
// '/bangalore/parking-near-KR-Puram',
// '/bangalore/parking-near-Kothanuru',
// '/bangalore/parking-near-Kumarswamy-layout',
// '/bangalore/parking-near-Madivala',
// '/bangalore/parking-near-Magadi-Road',
// '/bangalore/parking-near-Mahalaxmi-Layout',
// '/bangalore/parking-near-Nandini-Layout',
// '/bangalore/parking-near-Parappana-Agrahara',
// '/bangalore/parking-near-Peenya',
// '/bangalore/parking-near-Pulakeshinagar',
// '/bangalore/parking-near-Puttenahalli',
// '/bangalore/parking-near-RMC-Yard',
// '/bangalore/parking-near-RT-Nagar',
// '/bangalore/parking-near-Rajajinagar',
// '/bangalore/parking-near-Rajarajeswarinagar',
// '/bangalore/parking-near-Rajgopal-Nagar',
// '/bangalore/parking-near-Rama-Murthy-Nagar',
// '/bangalore/parking-near-SG-Palya',
// '/bangalore/parking-near-SJ-Park',
// '/bangalore/parking-near-SR-Nagar',
// '/bangalore/parking-near-Sampigehalli',
// '/bangalore/parking-near-Sanjaynagar',
// '/bangalore/parking-near-Shankarapurm',
// '/bangalore/parking-near-Sheshadripuram',
// '/bangalore/parking-near-Shivaji-Nagar',
// '/bangalore/parking-near-Siddapura',
// '/bangalore/parking-near-Soladevanahalli',
// '/bangalore/parking-near-Talaghattapura',
// '/bangalore/parking-near-Thilaknagar',
// '/bangalore/parking-near-Upparpet',
// '/bangalore/parking-near-VV-Puram',
// '/bangalore/parking-near-Varthur',
// '/bangalore/parking-near-Vidhana-Soudha',
// '/bangalore/parking-near-Vidyaranyapura',
// '/bangalore/parking-near-Viveknagar',
// '/bangalore/parking-near-Vyalikaval',
// '/bangalore/parking-near-Wilson-Garden',
// '/bangalore/parking-near-Women-PS',
// '/bangalore/parking-near-Yelahanka-New-Town',
// '/bangalore/parking-near-Yeshwanthapura',
// '/bangalore/parking-near-Cubbonpark',
// '/bangalore/parking-near-V.V.Puram',
// '/bangalore/parking-near-J.C.-Nagar',
],
// * If some thing goes wrong then
// todo: In the Vue.config.js file, make headless to false. By default,
// todo: it comes false, but in case you have turned it to true then make it false.
}),
],
};
}
},
// compression code
pluginOptions: {
compression: {
brotli: {
filename: '[file].br[query]',
algorithm: 'brotliCompress',
include: /\.(js|css|html|svg|json)(\?.*)?$/i,
compressionOptions: {
params: {
[zlib.constants.BROTLI_PARAM_QUALITY]: 11,
},
},
minRatio: 0.8,
},
gzip: {
filename: '[file].gz[query]',
algorithm: 'gzip',
include: /\.(js|css|html|svg|json)(\?.*)?$/i,
minRatio: 0.8,
},
},
},
};