1
0
mirror of https://github.com/kamranahmedse/developer-roadmap.git synced 2025-08-13 12:43:59 +02:00

Update link-groups

This commit is contained in:
Kamran Ahmed
2023-06-06 10:57:19 +01:00
parent 40d25c43f4
commit 0f80f26d17
3 changed files with 4 additions and 6 deletions

View File

@@ -1,4 +1,5 @@
---
byte-byte-go: https://blog.bytebytego.com/archive
speedup-js: https://marvinh.dev/blog/speeding-up-javascript-ecosystem/
23-min-ts: https://www.youtube.com/watch?v=YmxwicpROps
bun-vs-node: https://www.youtube.com/watch?v=qCX8rw4qOSA

View File

@@ -26,17 +26,14 @@ function linkGroupPathToId(filePath: string): string {
*/
export async function getAllLinkGroups(): Promise<LinkGroupFileType[]> {
const linkGroups = await import.meta.glob<LinkGroupFileType>(
'/src/link-groups/*.md',
'/src/data/link-groups/*.md',
{
eager: true,
}
);
const linkGroupFiles = Object.values(linkGroups);
const enrichedLinkGroups = linkGroupFiles.map((linkGroupFile) => ({
return Object.values(linkGroups).map((linkGroupFile) => ({
...linkGroupFile,
id: linkGroupPathToId(linkGroupFile.file),
}));
return enrichedLinkGroups;
}

View File

@@ -34,6 +34,6 @@ const fullUrl = linkGroup.frontmatter[linkId!];
<h2 class='text-xl font-bold'>Redirecting ..</h2>
<p>Click the link below if you are not redirected automatically.</p>
<p><a href={fullUrl} class='underline text-blue-700'>{fullUrl}</a></p>
<p><a href={fullUrl} class='text-blue-700 underline'>{fullUrl}</a></p>
</div>
</SkeletonLayout>