import { useParams } from "react-router-dom"; import { Algorithm as AlgorithmType } from "../types"; interface AlgorithmProps { algorithms: AlgorithmType[]; } function Algorithm({ algorithms }: AlgorithmProps) { const { algorithmName } = useParams<{ algorithmName: string }>(); const algorithm = algorithms.find((a) => a.name === algorithmName); if (!algorithm) { return
{algorithm.description}
{algorithm.version}