This commit is contained in:
@@ -1,24 +1,15 @@
|
||||
import { GetServerSideProps } from "next";
|
||||
import { MainLayout } from "../../layouts/MainLayout";
|
||||
import { Post, getAllProjectsFrontMatter } from "../../utils/markdown";
|
||||
import { FrontMatter } from "../../types/types";
|
||||
import Link from "next/link";
|
||||
import { formatDate } from "../../utils/general";
|
||||
|
||||
export interface BasicProjectProps extends FrontMatter {
|
||||
title: string;
|
||||
description: string;
|
||||
date: string;
|
||||
author: string;
|
||||
authorLink: string;
|
||||
thumbnail: string;
|
||||
}
|
||||
import { BasicArticleProps } from "../../components/PostHeader";
|
||||
|
||||
const ProjectCard = ({
|
||||
project,
|
||||
slug,
|
||||
}: {
|
||||
project: BasicProjectProps;
|
||||
project: BasicArticleProps;
|
||||
slug: string;
|
||||
}) => {
|
||||
return (
|
||||
@@ -55,7 +46,7 @@ const Projects = ({ posts }: { posts: Post[] }) => {
|
||||
{posts.map((post, index) => (
|
||||
<ProjectCard
|
||||
key={index}
|
||||
project={post.frontMatter as BasicProjectProps}
|
||||
project={post.frontMatter as BasicArticleProps}
|
||||
slug={post.slug}
|
||||
/>
|
||||
))}
|
||||
|
||||
Reference in New Issue
Block a user