mirror of
https://github.com/privacy-scaling-explorations/pse.dev.git
synced 2026-01-12 07:38:20 -05:00
* feat: general fixes wip * feat: complete general fixes - align side wiki - Enforce kebab-case on URLs (fix #309) - Search result don’t render markdown (fix #362) - Move “related projects” before “more articles”in blog page - Display research projects on projects page (fix #387) - Add support for youtube videos for projects (fix #384) - Add support for team member for projects (fix #385) * feat: "new articles" use new blog card component * feat: make articles card link more visible
17 lines
370 B
TypeScript
17 lines
370 B
TypeScript
import { projects } from "@/data/projects"
|
|
|
|
import { ProjectInterface } from "./types"
|
|
|
|
export const getProjectById = (id: string | number, lang = "en") => {
|
|
const project: ProjectInterface =
|
|
projects.filter((project) => String(project.id?.toLowerCase()) === id)[0] ??
|
|
{}
|
|
|
|
const content = project?.content?.[lang]
|
|
|
|
return {
|
|
project,
|
|
content,
|
|
}
|
|
}
|