-
Notifications
You must be signed in to change notification settings - Fork 23
Expand file tree
/
Copy pathvite.config.ts
More file actions
72 lines (70 loc) · 1.88 KB
/
vite.config.ts
File metadata and controls
72 lines (70 loc) · 1.88 KB
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
import { createMpaPlugin, createPages } from "vite-plugin-virtual-mpa";
import { defineConfig, normalizePath } from "vite";
import path from "path";
const pages = createPages([
{
name: "botw",
filename: "botw/index.html",
entry: "/src/botw.ts",
data: {
title: "Breath of the Wild Interactive Map",
description:
"Interactive, searchable map of Hyrule with locations, descriptions, guides, and more.",
},
},
{
name: "la",
filename: "la/index.html",
entry: "/src/la.ts",
data: {
title: "Link's Awakening Interactive Map (Nintendo Switch)",
description:
"Interactive, searchable map of Koholint with locations, descriptions, guides, and more.",
},
},
{
name: "totk",
filename: "totk/index.html",
entry: "/src/totk.ts",
data: {
title: "Tears of the Kingdom Interactive Map",
description:
"Interactive, searchable map of Hyrule with locations, descriptions, guides, and more.",
},
},
{
name: "eow",
filename: "eow/index.html",
entry: "/src/eow.ts",
data: {
title: "Echoes of Wisdom Interactive Map",
description:
"Interactive, searchable map of Hyrule with locations, descriptions, guides, and more.",
},
},
{
name: "ss",
filename: "ss/index.html",
entry: "/src/ss.ts",
data: {
title: "Skyward Sword Interactive Map",
description:
"Interactive, searchable map of Hyrule with locations, descriptions, guides, and more.",
},
},
]);
// tslint:disable-next-line:no-default-export vite convention
export default defineConfig(({ command, mode, ssrBuild }) => ({
base: mode === "production" ? "/maps/" : "/maps-beta/",
plugins: [
createMpaPlugin({
template: "src/template.html",
pages,
}),
],
resolve: {
alias: {
"@fonts": path.resolve(__dirname, "src", "fonts"),
},
},
}));