(s: str)
| 15 | |
| 16 | |
| 17 | def slugify(s: str) -> str: |
| 18 | s = s.lower().strip() |
| 19 | s = re.sub(r"[^a-z0-9]+", "-", s) |
| 20 | s = re.sub(r"-+", "-", s).strip("-") |
| 21 | return s or "lesson" |
| 22 | |
| 23 | |
| 24 | def split_frontmatter(text: str) -> Tuple[str, str]: |
no test coverage detected