mirror of
https://github.com/kemko/resume.git
synced 2026-01-04 09:15:48 +03:00
12 lines
285 B
TypeScript
12 lines
285 B
TypeScript
import mdToPdf from 'md-to-pdf';
|
|
|
|
export const markdownToPdf = async (inputFilePath: string) => {
|
|
try {
|
|
const pdf = await mdToPdf({ path: inputFilePath });
|
|
return pdf;
|
|
} catch (error: any) {
|
|
console.error(`Error occurred: ${error.message}`);
|
|
throw error;
|
|
}
|
|
}
|