Skip to content

Commit 061c1d5

Browse files
committed
Static render all combinations of convert formats
1 parent 7501b39 commit 061c1d5

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

vite.config.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ import { viteStaticCopy } from 'vite-plugin-static-copy'
77
const config = require('./src/config.json')
88
const English = require('./src/locales/en.json')
99

10+
const convertFormats = ['give-command', 'loot-table', 'item-modifier']
11+
1012
export default defineConfig({
1113
server: {
1214
port: 3000,
@@ -44,6 +46,11 @@ export default defineConfig({
4446
title: `${English[m.id] ?? ''} Generator${m.category === true ? 's' : ''} - ${getVersions(m)}`,
4547
template,
4648
})),
49+
...convertFormats.flatMap(s => convertFormats.filter(t => s !== t).map(t => [s, t])).map(([s, t]) => html({
50+
fileName: `convert/${s}-to-${t}/index.html`,
51+
title: `${English[`convert.format.${s}`]} to ${English[`convert.format.${t}`]} Converter - ${getVersions({ minVersion: '1.20.5' })}`,
52+
template,
53+
})),
4754
...config.legacyGuides.map(g => html({
4855
fileName: `guides/${g.id}/index.html`,
4956
title: `${g.title} - ${getVersions()}`,

0 commit comments

Comments
 (0)