refactor(parser): remove resources parsing, preview, and content_html fields

parse_readme now returns list[ParsedGroup] instead of a tuple. The
resources section (Newsletters, Podcasts), preview string, and
content_html rendering are no longer produced by the parser or consumed
by the build. Removes _render_section_html, _group_by_h2, and the
associated dead code and tests.

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Vinta Chen
2026-03-23 01:43:19 +08:00
parent c5dd3060ef
commit 25a3f4d903
4 changed files with 37 additions and 253 deletions
+1 -2
View File
@@ -139,7 +139,7 @@ def build(repo_root: str) -> None:
subtitle = stripped
break
parsed_groups, _ = parse_readme(readme_text)
parsed_groups = parse_readme(readme_text)
categories = [cat for g in parsed_groups for cat in g["categories"]]
total_entries = sum(c["entry_count"] for c in categories)
@@ -172,7 +172,6 @@ def build(repo_root: str) -> None:
(site_dir / "index.html").write_text(
tpl_index.render(
categories=categories,
groups=parsed_groups,
subtitle=subtitle,
entries=entries,
total_entries=total_entries,