mirror of
https://github.com/kamranahmedse/developer-roadmap.git
synced 2025-08-30 20:49:49 +02:00
Add author pages
This commit is contained in:
BIN
public/authors/peter-thaleikis.png
Normal file
BIN
public/authors/peter-thaleikis.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 150 KiB |
@@ -1,40 +1,38 @@
|
||||
---
|
||||
import type { VideoFileType } from '../lib/video';
|
||||
import YouTubeAlert from "./YouTubeAlert.astro";
|
||||
import YouTubeAlert from './YouTubeAlert.astro';
|
||||
|
||||
export interface Props {
|
||||
video: VideoFileType;
|
||||
}
|
||||
|
||||
const { video } = Astro.props;
|
||||
const { frontmatter } = video;
|
||||
const { author } = frontmatter;
|
||||
const { frontmatter, author } = video;
|
||||
---
|
||||
|
||||
<div class='bg-white border-b py-5 sm:py-12'>
|
||||
<div class='border-b bg-white py-5 sm:py-12'>
|
||||
<div class='container text-left sm:text-center'>
|
||||
<p
|
||||
class='text-gray-400 hidden sm:flex items-center justify-start sm:justify-center'
|
||||
class='hidden items-center justify-start text-gray-400 sm:flex sm:justify-center'
|
||||
>
|
||||
<a
|
||||
href={author.url}
|
||||
target='_blank'
|
||||
class='font-medium hover:text-gray-600 inline-flex items-center hover:underline'
|
||||
href={`/authors/${author.id}`}
|
||||
class='inline-flex items-center font-medium hover:text-gray-600 hover:underline'
|
||||
>
|
||||
<img
|
||||
alt={author.name}
|
||||
src={author.imageUrl}
|
||||
class='w-5 h-5 inline mr-2 rounded-full'
|
||||
alt={author.frontmatter.name}
|
||||
src={author.frontmatter.imageUrl}
|
||||
class='mr-2 inline h-5 w-5 rounded-full'
|
||||
/>
|
||||
{author.name}
|
||||
{author.frontmatter.name}
|
||||
</a>
|
||||
<span class='mx-1.5'>·</span>
|
||||
<span class='capitalize'>Illustrated Video</span>
|
||||
</p>
|
||||
<h1 class='text-2xl sm:text-5xl my-0 sm:my-3.5 font-bold'>
|
||||
<h1 class='my-0 text-2xl font-bold sm:my-3.5 sm:text-5xl'>
|
||||
{frontmatter.title}
|
||||
</h1>
|
||||
<p class='hidden sm:block text-gray-400 text-md'>
|
||||
<p class='text-md hidden text-gray-400 sm:block'>
|
||||
{frontmatter.description}
|
||||
</p>
|
||||
</div>
|
||||
|
8
src/data/authors/ebrahim-bharmal.md
Normal file
8
src/data/authors/ebrahim-bharmal.md
Normal file
@@ -0,0 +1,8 @@
|
||||
---
|
||||
name: 'Ebrahim Bharmal'
|
||||
imageUrl: '/authors/ebrahimbharmal007.png'
|
||||
social:
|
||||
twitter: 'https://twitter.com/BharmalEbrahim'
|
||||
---
|
||||
|
||||
Full-stack developer interested in all things web development.
|
9
src/data/authors/jesse-li.md
Normal file
9
src/data/authors/jesse-li.md
Normal file
@@ -0,0 +1,9 @@
|
||||
---
|
||||
name: 'Jesse Li'
|
||||
imageUrl: '/authors/jesse.png'
|
||||
social:
|
||||
twitter: 'https://twitter.com/__jesse_li'
|
||||
github: 'https://github.com/veggiedefender'
|
||||
---
|
||||
|
||||
Jesse has made several [interesting open-source projects](https://github.com/veggiedefender) and wrote some interesting [articles on his blog](https://blog.jse.li/) including the one he wrote on roadmap.sh.
|
9
src/data/authors/peter-thaleikis.md
Normal file
9
src/data/authors/peter-thaleikis.md
Normal file
@@ -0,0 +1,9 @@
|
||||
---
|
||||
name: 'Peter Thaleikis'
|
||||
imageUrl: '/authors/peter-thaleikis.png'
|
||||
social:
|
||||
twitter: 'https://twitter.com/spekulatius1984'
|
||||
website: 'https://peterthaleikis.com/'
|
||||
---
|
||||
|
||||
Peter Thaleikis a software engineer and business owner. He has been developing web applications since around 2000. Before he started his own software development company [Bring Your Own Ideas Ltd.](https://bringyourownideas.com/), he has been a Lead Developer for multiple organizations.
|
@@ -1,10 +1,7 @@
|
||||
---
|
||||
title: 'Proxy Servers'
|
||||
description: 'How do proxy servers work and what are forward and reverse proxies?'
|
||||
author:
|
||||
name: 'Ebrahim Bharmal'
|
||||
url: 'https://twitter.com/BharmalEbrahim'
|
||||
imageUrl: '/authors/ebrahimbharmal007.png'
|
||||
authorId: 'ebrahim-bharmal'
|
||||
seo:
|
||||
title: 'Proxy Servers - roadmap.sh'
|
||||
description: 'How do proxy servers work and what are forward and reverse proxies?'
|
||||
|
@@ -1,10 +1,7 @@
|
||||
---
|
||||
title: 'Building a BitTorrent Client'
|
||||
description: 'Learn everything you need to know about BitTorrent by writing a client in Go'
|
||||
author:
|
||||
name: 'Jesse Li'
|
||||
url: 'https://twitter.com/__jesse_li'
|
||||
imageUrl: '/authors/jesse.png'
|
||||
authorId: 'jesse-li'
|
||||
seo:
|
||||
title: 'Building a BitTorrent Client - roadmap.sh'
|
||||
description: 'Learn everything you need to know about BitTorrent by writing a client in Go'
|
||||
|
@@ -1,10 +1,7 @@
|
||||
---
|
||||
title: 'Build it and they will come?'
|
||||
description: 'Why “build it and they will come” alone won’t work anymore'
|
||||
author:
|
||||
name: 'Peter Thaleikis'
|
||||
url: 'https://twitter.com/spekulatius1984'
|
||||
imageUrl: '/authors/spekulatius.jpg'
|
||||
authorId: 'peter-thaleikis'
|
||||
seo:
|
||||
title: 'Build it and they will come? - roadmap.sh'
|
||||
description: 'Why “build it and they will come” alone won’t work anymore'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn what it means for a database to be ACID compliant with examp
|
||||
duration: '5 minutes'
|
||||
isNew: false
|
||||
date: 2021-09-26
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn what is HTTP caching, places for caching and different cachi
|
||||
duration: '13 minutes'
|
||||
isNew: false
|
||||
date: 2020-10-04
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn everything you need to know about array data structure'
|
||||
duration: '10 minutes'
|
||||
isNew: false
|
||||
date: 2022-01-09
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn how to manipulate arrays and objects in JavaScript.'
|
||||
duration: '12 minutes'
|
||||
isNew: false
|
||||
date: 2020-05-09
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn how to write asynchronous JavaScript using Async/Await'
|
||||
duration: '15 minutes'
|
||||
isNew: false
|
||||
date: 2021-11-14
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn everything you need to know about basic authentication'
|
||||
duration: '5 minutes'
|
||||
isNew: false
|
||||
date: 2022-10-01
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn everything you need to know about authentication with this A
|
||||
duration: '5 minutes'
|
||||
isNew: false
|
||||
date: 2022-09-21
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn what the Big-O notation is and how to calculate the time com
|
||||
duration: '8 minutes'
|
||||
isNew: false
|
||||
date: 2021-10-25
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn what the CDNs are and the difference between push CDN vs pul
|
||||
duration: '4 minutes'
|
||||
isNew: false
|
||||
date: 2020-09-26
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn what the DNS is and how a website is found on the internet.'
|
||||
duration: '5 minutes'
|
||||
isNew: false
|
||||
date: 2020-08-17
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn what the DNS is and how a website is found on the internet.'
|
||||
duration: '6 minutes'
|
||||
isNew: false
|
||||
date: 2020-08-31
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn how ow the arithmetic operations work on floating-point numb
|
||||
duration: '4 minutes'
|
||||
isNew: false
|
||||
date: 2021-10-10
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn what is object freeze and seal in JavaScript and how to use
|
||||
duration: '6 minutes'
|
||||
isNew: false
|
||||
date: 2020-10-16
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn everything you need to know about the graph data structure'
|
||||
duration: '13 minutes'
|
||||
isNew: false
|
||||
date: 2022-09-08
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn everything you need to know about the hash table data struct
|
||||
duration: '8 minutes'
|
||||
isNew: false
|
||||
date: 2022-02-21
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn everything you need to know about the heap data structure'
|
||||
duration: '11 minutes'
|
||||
isNew: false
|
||||
date: 2022-08-24
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn how to write scalable CSS using CSS Variables.'
|
||||
duration: '5 minutes'
|
||||
isNew: false
|
||||
date: 2020-07-03
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn how to implement CI/CD with GitHub Actions'
|
||||
duration: '6 minutes'
|
||||
isNew: false
|
||||
date: 2020-07-13
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: "Learn how to use JavaScript's Fetch API to interact with remote AP
|
||||
duration: '3 minutes'
|
||||
isNew: false
|
||||
date: 2020-08-02
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn everything you need to know about linked list data structure
|
||||
duration: '11 minutes'
|
||||
isNew: false
|
||||
date: 2022-01-31
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn the basics of load balancers, types and different algorithms
|
||||
duration: '9 minutes'
|
||||
isNew: false
|
||||
date: 2020-09-18
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn what is OSI Model and the different layers involved.'
|
||||
duration: '7 minutes'
|
||||
isNew: false
|
||||
date: 2020-10-24
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn how to create a React Application with practical example.'
|
||||
duration: '40 minutes'
|
||||
isNew: false
|
||||
date: 2020-07-09
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn how to write asynchronous code in JavaScript using promises.
|
||||
duration: '8 minutes'
|
||||
isNew: false
|
||||
date: 2020-07-20
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn everything you need to know about the queue data structure'
|
||||
duration: '4 minutes'
|
||||
isNew: false
|
||||
date: 2022-02-14
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'How do random number generators work?'
|
||||
duration: '8 minutes'
|
||||
isNew: false
|
||||
date: 2021-11-03
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn the basics of System Design and understand how to build a sc
|
||||
duration: '10 minutes'
|
||||
isNew: false
|
||||
date: 2020-07-26
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn everything you need to know about session authentication'
|
||||
duration: '2 minutes'
|
||||
isNew: false
|
||||
date: 2022-11-02
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn the difference between SSH, TLS and SSL'
|
||||
duration: '3 minutes'
|
||||
isNew: false
|
||||
date: 2021-11-25
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn everything you need to know about the stack data structure'
|
||||
duration: '5 minutes'
|
||||
isNew: false
|
||||
date: 2022-02-07
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn about all the bits and pieces of system design.'
|
||||
duration: '7 minutes'
|
||||
isNew: false
|
||||
date: 2020-08-08
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn what is TCP/IP Model and the different layers involved.'
|
||||
duration: '5 minutes'
|
||||
isNew: false
|
||||
date: 2020-11-06
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn about the Transport Layer of the TCP/IP model and different
|
||||
duration: '10 minutes'
|
||||
isNew: false
|
||||
date: 2020-11-21
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn everything you need to know about the tree data structure'
|
||||
duration: '8 minutes'
|
||||
isNew: false
|
||||
date: 2022-08-11
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn about the different data structures in this illustrated seri
|
||||
duration: '1 minute'
|
||||
isNew: false
|
||||
date: 2021-12-12
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'An illustrated explanation to CAP theorem with examples and proof.
|
||||
duration: '8 minutes'
|
||||
isNew: false
|
||||
date: 2021-10-05
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn what is dependency injection and how to write better code wi
|
||||
duration: '3 minutes'
|
||||
isNew: false
|
||||
date: 2020-07-04
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn what is DOM, Shadow DOM and Virtual DOM and how they work.'
|
||||
duration: '6 minutes'
|
||||
isNew: false
|
||||
date: 2020-07-20
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Learn about the different consistency models in distributed system
|
||||
duration: '5 minutes'
|
||||
isNew: false
|
||||
date: 2021-11-30
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -4,10 +4,7 @@ description: 'Everything you need to know about YAML'
|
||||
duration: '8 minutes'
|
||||
isNew: false
|
||||
date: 2021-10-18
|
||||
author:
|
||||
name: 'Kamran Ahmed'
|
||||
url: 'https://twitter.com/kamrify'
|
||||
imageUrl: '/authors/kamranahmedse.jpeg'
|
||||
authorId: 'kamran'
|
||||
sitemap:
|
||||
priority: 0.7
|
||||
changefreq: 'weekly'
|
||||
|
@@ -1,14 +1,13 @@
|
||||
import type { MarkdownFileType } from './file';
|
||||
import type {AuthorFileType} from "./author.ts";
|
||||
import type { AuthorFileType } from './author.ts';
|
||||
import { getAllAuthors } from './author.ts';
|
||||
import type {GuideFileType} from "./guide.ts";
|
||||
import {getAllGuides} from "./guide.ts";
|
||||
|
||||
export interface VideoFrontmatter {
|
||||
title: string;
|
||||
description: string;
|
||||
author: {
|
||||
name: string;
|
||||
url: string;
|
||||
imageUrl: string;
|
||||
};
|
||||
authorId: string;
|
||||
seo: {
|
||||
title: string;
|
||||
description: string;
|
||||
@@ -40,6 +39,14 @@ function videoPathToId(filePath: string): string {
|
||||
return fileName.replace('.md', '');
|
||||
}
|
||||
|
||||
export async function getVideosByAuthor(
|
||||
authorId: string,
|
||||
): Promise<VideoFileType[]> {
|
||||
const allVideos = await getAllVideos();
|
||||
|
||||
return allVideos.filter((video) => video.author?.id === authorId);
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets all the videos sorted by the publishing date
|
||||
* @returns Promisifed video files
|
||||
@@ -49,10 +56,15 @@ export async function getAllVideos(): Promise<VideoFileType[]> {
|
||||
eager: true,
|
||||
});
|
||||
|
||||
const allAuthors = await getAllAuthors();
|
||||
|
||||
const videoFiles = Object.values(videos);
|
||||
const enrichedVideos = videoFiles.map((videoFile) => ({
|
||||
...videoFile,
|
||||
id: videoPathToId(videoFile.file),
|
||||
author: allAuthors.find(
|
||||
(author) => author.id === videoFile.frontmatter.authorId,
|
||||
)!,
|
||||
}));
|
||||
|
||||
return enrichedVideos.sort(
|
||||
|
@@ -2,9 +2,10 @@
|
||||
import BaseLayout from '../../layouts/BaseLayout.astro';
|
||||
import AstroIcon from '../../components/AstroIcon.astro';
|
||||
import { getGuidesByAuthor } from '../../lib/guide';
|
||||
import { getAllVideos } from '../../lib/video';
|
||||
import {getAllVideos, getVideosByAuthor} from '../../lib/video';
|
||||
import GuideListItem from '../../components/GuideListItem.astro';
|
||||
import { getAuthorById, getAuthorIds } from '../../lib/author';
|
||||
import VideoListItem from "../../components/VideoListItem.astro";
|
||||
|
||||
interface Params extends Record<string, string | undefined> {}
|
||||
|
||||
@@ -18,10 +19,13 @@ export async function getStaticPaths() {
|
||||
|
||||
const { authorId } = Astro.params;
|
||||
|
||||
console.log(authorId);
|
||||
|
||||
const author = await getAuthorById(authorId);
|
||||
|
||||
console.log(author);
|
||||
const guides = await getGuidesByAuthor(authorId);
|
||||
const videos = await getAllVideos();
|
||||
const videos = await getVideosByAuthor(authorId);
|
||||
---
|
||||
|
||||
<BaseLayout
|
||||
@@ -35,7 +39,7 @@ const videos = await getAllVideos();
|
||||
<div class='container pt-4 pb-0 md:pb-16 md:pt-8'>
|
||||
<div class=''>
|
||||
<div class='mb-5 flex items-center gap-8 rounded-3xl py-0 md:py-8'>
|
||||
<div>
|
||||
<div class="flex-grow">
|
||||
<h1 class='text-2xl md:text-3xl font-bold'>{author.frontmatter.name}</h1>
|
||||
<div
|
||||
class='mt-1 mb-4 md:mt-4 md:mb-6 flex flex-col gap-3 text-gray-800 [&>p>a]:font-semibold [&>p>a]:underline leading-normal'
|
||||
@@ -105,6 +109,7 @@ const videos = await getAllVideos();
|
||||
class='rounded-t-xl bg-gradient-to-b from-gray-100 to-white px-3 py-2 md:px-6 md:py-3 [&>*:last-child]:border-b-0'
|
||||
>
|
||||
{guides.map((guide) => <GuideListItem guide={guide} />)}
|
||||
{videos.map((video) => <VideoListItem video={video} />)}
|
||||
</div>
|
||||
</div>
|
||||
</BaseLayout>
|
||||
|
Reference in New Issue
Block a user