diff --git a/next.config.js b/next.config.js
index 2923298aa..2548ca6e6 100644
--- a/next.config.js
+++ b/next.config.js
@@ -1,15 +1,28 @@
import { createVanillaExtractPlugin } from '@vanilla-extract/next-plugin';
+import { readdirSync, writeFileSync } from 'fs';
const withVanillaExtract = createVanillaExtractPlugin({ tests: /\.css$/ });
/** @type {import('next').NextConfig} */
const nextConfig = {
...withVanillaExtract({
- webpack: (config) => {
+ webpack: (config, { isServer }) => {
config.module.rules.push({
test: /\.glsl$/,
type: 'asset/source',
});
+
+ if (isServer) {
+ writeFileSync(
+ 'public/assets/versions.json',
+ JSON.stringify(
+ readdirSync('docs/changelogs').map((file) =>
+ file.replace('.md', ''),
+ ),
+ ),
+ );
+ }
+
return config;
},
}),
diff --git a/public/assets/versions.json b/public/assets/versions.json
new file mode 100644
index 000000000..a5d21bbc5
--- /dev/null
+++ b/public/assets/versions.json
@@ -0,0 +1 @@
+["1.10.0","1.10.1","1.10.2","1.11.0","1.12.0","1.12.1","1.12.2","1.12.3","1.12.4","1.12.5","1.12.6","1.12.7","1.12.8","1.12.9","1.13.0","1.13.1","1.13.2","1.13.3","1.14.0","1.14.1","1.14.2","1.14.3","1.14.4","1.15.0","1.15.1","1.15.10","1.15.11","1.15.12","1.15.13","1.15.2","1.15.3","1.15.4","1.15.5","1.15.6","1.15.7","1.15.8","1.15.9","1.16.0","1.16.1","1.16.2","1.16.3","1.16.4","1.17.0","1.17.1","1.17.2","1.18.0","1.18.1","1.18.2","1.18.3","1.19.0","1.19.1","1.19.2","1.19.3","1.19.4","1.19.5","1.19.6","1.20.0","1.20.1","1.20.2","1.20.3","1.3.0","1.3.1","1.3.2","1.3.3","1.4.0","1.4.1","1.5.0","1.5.1","1.5.2","1.5.3","1.5.4","1.6.0","1.7.0","1.7.1","1.7.2","1.7.3-1.7.4","1.7.5","1.7.6","1.7.7","1.8.0","1.8.1","1.9.0","1.9.1","1.9.2","1.9.3","1.9.4","1.9.5"]
\ No newline at end of file
diff --git a/src/app/docs/patches/page.tsx b/src/app/docs/patches/page.tsx
new file mode 100644
index 000000000..26b27c9c5
--- /dev/null
+++ b/src/app/docs/patches/page.tsx
@@ -0,0 +1,26 @@
+import { Flex, Heading } from '@radix-ui/themes';
+import { compareVersions } from 'compare-versions';
+import versions from '../../../../public/assets/versions.json';
+import { Link } from '../../../components/Link';
+import PageWrapper from '../../../components/PageWrapper';
+
+export default async function Page() {
+ return (
+
+ BlitzKit patch notes
+
+
+ {versions
+ .sort(compareVersions)
+ .reverse()
+ .map((version) => {
+ return (
+
+ {version}
+
+ );
+ })}
+
+
+ );
+}
diff --git a/src/components/Footer/index.tsx b/src/components/Footer/index.tsx
index c89f812a8..86515df49 100644
--- a/src/components/Footer/index.tsx
+++ b/src/components/Footer/index.tsx
@@ -72,6 +72,9 @@ export function Footer() {
>
GitHub
+
+ Patches
+
{/* patreon supporters? */}