smelt.html¶
Tier: Host — Available in every runtime, including headless mode.
HTML parsing: title extraction, link scraping, to_text, to_markdown, DDG results.
smelt.html.links¶
Extract all anchor href links from source. When base is supplied, relative URLs are resolved against it.
smelt.html.parse_ddg_results¶
Parse a DuckDuckGo HTML results page into rows of { title, link, description }.
smelt.html.title¶
Return the <title> text of source, or nil if no title element is present.
smelt.html.to_markdown¶
Convert source HTML to a { title, content, links } table where content is markdown. Relative links resolve against base when supplied.
smelt.html.to_text¶
Strip HTML tags from source and return the visible text content.