Carson Gross, creator of htmx and hyperscript, walks through a real bug fix in the hyperscript parser to illustrate both the strengths and limitations of AI coding assistance. Claude helped quickly identify the root cause of a parsing regression (an `as` keyword binding conflict introduced during a refactor) and generated useful tests, but its proposed fixes were either too narrow, too hacky, or introduced unnecessary complexity. The final correct fix required Gross's own understanding of the parser's existing 'follows' infrastructure to scope the change precisely to the `fetch` command without affecting `go`. The essay argues that a knowledgeable human in the loop is essential to prevent AI from accruing technical debt, and contrasts this with vibe coding where developers accept AI solutions without understanding them. Gross also reflects on how AI helps older developers compensate for memory and stamina limitations, while worrying it may accelerate cognitive decline.

10m read timeFrom htmx.org
Post cover image
Table of contents
The Hyperscript ParserA Bug ReportInvestigating The CauseFixing The IssueProposed Fix 1: A HackProposed Fix 2: Better But Unnecessary ComplexityProposed Fix 3: Close, But No CigarThe Final, Semi-Organic FixTestsThe Moral of The StoryAside: AI & The Older DeveloperConclusion
11.8K Impressions2 Comments