---
import * as fs from 'node:fs';
import HighlightedCode from '@components/HighlightedCode.astro';

interface Props {
	path: string;
	lang?: string;
}

const { path: filePath, lang = 'julia' } = Astro.props;
const code = fs.readFileSync(filePath, 'utf8');
---

<HighlightedCode code={code} lang={lang} />
