(text: string)
| 33 | } |
| 34 | |
| 35 | function slugify(text: string): string { |
| 36 | return text |
| 37 | .toLowerCase() |
| 38 | .trim() |
| 39 | .replace(/[^a-z0-9\s-]/g, '') |
| 40 | .replace(/\s+/g, '-') |
| 41 | } |
| 42 | |
| 43 | async function scanFrontmatters(): Promise<BlogMeta[]> { |
| 44 | if (cachedMeta) { |
no test coverage detected