Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion astro.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,11 @@ import preact from '@astrojs/preact';

import compress from 'astro-compress';

import sitemap from '@astrojs/sitemap';

// https://astro.build/config
export default defineConfig({
site: 'https://www.acm.illinois.edu',
output: 'static',
outDir: './build',
vite: {
Expand All @@ -20,7 +23,15 @@ export default defineConfig({
server: {
port: 3000,
},
integrations: [mdx(), icon(), preact({ compat: true }), compress()],
integrations: [
mdx(),
icon(),
preact({ compat: true }),
compress(),
sitemap({
filter: (page) => !page.startsWith('https://www.acm.illinois.edu/admin/'),
}),
],
experimental: {
svgo: true,
},
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
"dependencies": {
"@acm-uiuc/core-client": "^4.1.11",
"@acm-uiuc/js-shared": "^3.5.0",
"@astrojs/sitemap": "^3.7.0",
"@azure/msal-browser": "^4.15.0",
"@azure/msal-react": "^3.0.25",
"@iconify-json/lucide": "^1.2.88",
Expand Down
4 changes: 4 additions & 0 deletions public/robots.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
User-agent: *
Disallow: /admin

Sitemap: https://www.acm.illinois.edu/sitemap-index.xml
5 changes: 2 additions & 3 deletions src/components/HeadMetadata.astro
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,10 @@ const { title = 'ACM @ UIUC', description, contentType } = Astro.props;
<head>
<meta charset="utf-8" />
<link rel="icon" href="/favicon.ico" />
<link rel="sitemap" href="/sitemap-index.xml" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="generator" content={Astro.generator} />
<meta name="description" content={description} />
<title>{title}</title>
<meta property="og:title" content={title} />
{description && <meta name="description" content={description} />}
{description && <meta property="og:description" content={description} />}
{contentType && <meta property="og:type" content={contentType} />}
</head>
41 changes: 41 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,15 @@
dependencies:
prismjs "^1.30.0"

"@astrojs/sitemap@^3.7.0":
version "3.7.0"
resolved "https://registry.yarnpkg.com/@astrojs/sitemap/-/sitemap-3.7.0.tgz#26ffe9b2f51e2720e5e96f358ecc20f4d87f7218"
integrity sha512-+qxjUrz6Jcgh+D5VE1gKUJTA3pSthuPHe6Ao5JCxok794Lewx8hBFaWHtOnN0ntb2lfOf7gvOi9TefUswQ/ZVA==
dependencies:
sitemap "^8.0.2"
stream-replace-string "^2.0.0"
zod "^3.25.76"

"@astrojs/telemetry@3.3.0":
version "3.3.0"
resolved "https://registry.npmjs.org/@astrojs/telemetry/-/telemetry-3.3.0.tgz"
Expand Down Expand Up @@ -1472,6 +1481,11 @@
dependencies:
undici-types "~7.16.0"

"@types/node@^17.0.5":
version "17.0.45"
resolved "https://registry.yarnpkg.com/@types/node/-/node-17.0.45.tgz#2c0fafd78705e7a18b7906b5201a522719dc5190"
integrity sha512-w+tIMs3rq2afQdsPJlODhoUEKzFP1ayaoyl1CcnwtIlsVe7K7bA1NGm4s3PraqTLlXnbIN84zuBlxBWo1u9BLw==

"@types/prop-types@*":
version "15.7.15"
resolved "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.15.tgz"
Expand Down Expand Up @@ -1505,6 +1519,13 @@
dependencies:
csstype "^3.2.2"

"@types/sax@^1.2.1":
version "1.2.7"
resolved "https://registry.yarnpkg.com/@types/sax/-/sax-1.2.7.tgz#ba5fe7df9aa9c89b6dff7688a19023dd2963091d"
integrity sha512-rO73L89PJxeYM3s3pPPjiPgVVcymqU490g0YO5n5By0k2Erzj6tay/4lr1CHAAU4JyOWd1rpQ8bCf6cZfHU96A==
dependencies:
"@types/node" "*"

"@types/unist@*", "@types/unist@^3.0.0":
version "3.0.3"
resolved "https://registry.npmjs.org/@types/unist/-/unist-3.0.3.tgz"
Expand Down Expand Up @@ -1803,6 +1824,11 @@ anymatch@^3.1.3:
normalize-path "^3.0.0"
picomatch "^2.0.4"

arg@^5.0.0:
version "5.0.2"
resolved "https://registry.yarnpkg.com/arg/-/arg-5.0.2.tgz#c81433cc427c92c4dcf4865142dbca6f15acd59c"
integrity sha512-PYjyFOLKQ9y57JvQ6QLo8dAgNqswh8M1RMJYdQduT6xbWSgK36P/Z/v+p888pM69jMMfS8Xd8F6I1kQ/I9HUGg==

argparse@^2.0.1:
version "2.0.1"
resolved "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz"
Expand Down Expand Up @@ -6389,6 +6415,16 @@ sisteransi@^1.0.5:
resolved "https://registry.npmjs.org/sisteransi/-/sisteransi-1.0.5.tgz"
integrity sha512-bLGGlR1QxBcynn2d5YmDX4MGjlZvy2MRBDRNHLJ8VI6l6+9FUiyTFNJ0IveOSP0bcXgVDPRcfGqA0pjaqUpfVg==

sitemap@^8.0.2:
version "8.0.2"
resolved "https://registry.yarnpkg.com/sitemap/-/sitemap-8.0.2.tgz#27bddb5fc2c61a1cf8f0194674cd89d762c9f5ae"
integrity sha512-LwktpJcyZDoa0IL6KT++lQ53pbSrx2c9ge41/SeLTyqy2XUNA6uR4+P9u5IVo5lPeL2arAcOKn1aZAxoYbCKlQ==
dependencies:
"@types/node" "^17.0.5"
"@types/sax" "^1.2.1"
arg "^5.0.0"
sax "^1.4.1"

slice-ansi@^7.1.0:
version "7.1.2"
resolved "https://registry.yarnpkg.com/slice-ansi/-/slice-ansi-7.1.2.tgz#adf7be70aa6d72162d907cd0e6d5c11f507b5403"
Expand Down Expand Up @@ -6461,6 +6497,11 @@ stop-iteration-iterator@^1.1.0:
es-errors "^1.3.0"
internal-slot "^1.1.0"

stream-replace-string@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/stream-replace-string/-/stream-replace-string-2.0.0.tgz#e49fd584bd1c633613e010bc73b9db49cb5024ad"
integrity sha512-TlnjJ1C0QrmxRNrON00JvaFFlNh5TTG00APw23j74ET7gkQpTASi6/L2fuiav8pzK715HXtUeClpBTw2NPSn6w==

string-argv@^0.3.2:
version "0.3.2"
resolved "https://registry.yarnpkg.com/string-argv/-/string-argv-0.3.2.tgz#2b6d0ef24b656274d957d54e0a4bbf6153dc02b6"
Expand Down