diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/pages/avatar.jpg | bin | 0 -> 7765 bytes | |||
-rw-r--r-- | src/pages/avatar.jpg.license | 6 | ||||
-rw-r--r-- | src/pages/index.tsx | 2 | ||||
-rw-r--r-- | src/plugins/swcMinifyPlugin.ts | 2 | ||||
-rw-r--r-- | src/plugins/thirdPartyContentPlugin.ts | 28 |
5 files changed, 36 insertions, 2 deletions
diff --git a/src/pages/avatar.jpg b/src/pages/avatar.jpg new file mode 100644 index 0000000..811b7a9 --- /dev/null +++ b/src/pages/avatar.jpg | |||
Binary files differ | |||
diff --git a/src/pages/avatar.jpg.license b/src/pages/avatar.jpg.license new file mode 100644 index 0000000..d1e6b86 --- /dev/null +++ b/src/pages/avatar.jpg.license | |||
@@ -0,0 +1,6 @@ | |||
1 | SPDX-FileCopyrightText: 2024 Kristóf Marussy <kristof@marussy.com> | ||
2 | |||
3 | SPDX-License-Identifier: CC0-1.0 | ||
4 | |||
5 | Placeholder image to replace the following third-party content: | ||
6 | photo taken by SPOT Fotókör <https://spot.sch.bme.hu/>. | ||
diff --git a/src/pages/index.tsx b/src/pages/index.tsx index 1a2b114..125c5d3 100644 --- a/src/pages/index.tsx +++ b/src/pages/index.tsx | |||
@@ -14,7 +14,7 @@ import Software from '@site/src/components/landing/sections/Software'; | |||
14 | import Section from '@site/src/components/landing/Section'; | 14 | import Section from '@site/src/components/landing/Section'; |
15 | import TrackActiveSection from '@site/src/components/TrackActiveSection'; | 15 | import TrackActiveSection from '@site/src/components/TrackActiveSection'; |
16 | 16 | ||
17 | import avatar from './avatar.jpg'; | 17 | import avatar from '@site/src/pages/avatar.jpg'; |
18 | 18 | ||
19 | export default function Home() { | 19 | export default function Home() { |
20 | return ( | 20 | return ( |
diff --git a/src/plugins/swcMinifyPlugin.ts b/src/plugins/swcMinifyPlugin.ts index 2586076..d4b4c4c 100644 --- a/src/plugins/swcMinifyPlugin.ts +++ b/src/plugins/swcMinifyPlugin.ts | |||
@@ -18,7 +18,7 @@ import TerserPlugin from 'terser-webpack-plugin'; | |||
18 | */ | 18 | */ |
19 | export default function swcMinifyPlugin(): Plugin { | 19 | export default function swcMinifyPlugin(): Plugin { |
20 | return { | 20 | return { |
21 | name: 'kris-swc-minify-plugin', | 21 | name: 'marussy-swc-minify-plugin', |
22 | configureWebpack: (config) => ({ | 22 | configureWebpack: (config) => ({ |
23 | mergeStrategy: { | 23 | mergeStrategy: { |
24 | 'optimization.minimizer': 'replace', | 24 | 'optimization.minimizer': 'replace', |
diff --git a/src/plugins/thirdPartyContentPlugin.ts b/src/plugins/thirdPartyContentPlugin.ts new file mode 100644 index 0000000..d2da4ab --- /dev/null +++ b/src/plugins/thirdPartyContentPlugin.ts | |||
@@ -0,0 +1,28 @@ | |||
1 | /* | ||
2 | * Copyright (c) 2024 Kristóf Marussy <kristof@marussy.com> | ||
3 | * | ||
4 | * SPDX-License-Identifier: MIT | ||
5 | */ | ||
6 | |||
7 | import path from 'node:path'; | ||
8 | |||
9 | import type { LoadContext, Plugin } from '@docusaurus/types'; | ||
10 | |||
11 | export default function thirdPartyContentPlugin({ | ||
12 | siteDir, | ||
13 | }: LoadContext): Plugin { | ||
14 | const thirdPartyDir = path.join(siteDir, 'third-party'); | ||
15 | return { | ||
16 | name: 'marussy-third-party-content-plugin', | ||
17 | configureWebpack: () => ({ | ||
18 | mergeStrategy: { | ||
19 | 'resolve.alias.@site': 'replace', | ||
20 | }, | ||
21 | resolve: { | ||
22 | alias: { | ||
23 | '@site': [thirdPartyDir, siteDir], | ||
24 | }, | ||
25 | }, | ||
26 | }), | ||
27 | }; | ||
28 | } | ||