{"id":31786726,"url":"https://github.com/defactosoftware/fast_html","last_synced_at":"2026-02-18T07:31:34.540Z","repository":{"id":196998802,"uuid":"697784539","full_name":"DefactoSoftware/fast_html","owner":"DefactoSoftware","description":"Elixir/Erlang bindings for lexborisov's myhtml. THIS IS A MIRROR, real repo at https://git.pleroma.social/pleroma/elixir-libraries/fast_html","archived":false,"fork":false,"pushed_at":"2025-10-06T18:36:20.000Z","size":1530,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-10-14T15:06:10.430Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"HTML","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"rinpatch/fast_html","license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DefactoSoftware.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSES/BSD-3-Clause.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-09-28T13:22:03.000Z","updated_at":"2025-10-06T18:36:23.000Z","dependencies_parsed_at":null,"dependency_job_id":"e5defbb6-7d18-4751-9710-b7ab1ab5dc19","html_url":"https://github.com/DefactoSoftware/fast_html","commit_stats":null,"previous_names":["defactosoftware/fast_html"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/DefactoSoftware/fast_html","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DefactoSoftware%2Ffast_html","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DefactoSoftware%2Ffast_html/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DefactoSoftware%2Ffast_html/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DefactoSoftware%2Ffast_html/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DefactoSoftware","download_url":"https://codeload.github.com/DefactoSoftware/fast_html/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DefactoSoftware%2Ffast_html/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29572395,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-18T06:19:27.422Z","status":"ssl_error","status_checked_at":"2026-02-18T06:18:44.348Z","response_time":162,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-10-10T13:21:14.900Z","updated_at":"2026-02-18T07:31:34.534Z","avatar_url":"https://github.com/DefactoSoftware.png","language":"HTML","readme":"\u003c!--\nSPDX-FileCopyrightText: 2017-2019 myhtmlex authors \u003chttps://github.com/Overbryd/myhtmlex\u003e\nSPDX-FileCopyrightText: 2019-2022 Pleroma Authors \u003chttps://pleroma.social\u003e\nSPDX-License-Identifier: LGPL-2.1-only\n--\u003e\n\n# FastHTML\n\nA C Node wrapping [lexbor](https://github.com/lexbor/lexbor).\nPrimarily used with [FastSanitize](https://git.pleroma.social/pleroma/fast_sanitize).\n\n* Available as a hex package: `{:fast_html, \"~\u003e 2.0\"}`\n* [Documentation](https://hexdocs.pm/fast_html/fast_html.html)\n\n## Compiling\n- GNU Make\n- C Compiler\n- Erlang 22.0+ with development headers\n- (optional) [lexbor](https://github.com/lexbor/lexbor) 2.2.0+\n\nIf you want to use a system installation of lexbor, you can set `WITH_SYSTEM_LEXBOR=1` during compilation time. By default it will used the vendored version present at `c_src/lexbor`.\n\n## Benchmarks\n\nThe following table provides median times it takes to decode a string to a tree for html parsers that can be used from Elixir. Benchmarks were conducted on a machine with an `AMD Ryzen 9 3950X (32) @ 3.500GHz` CPU and 32GB of RAM. The `mix fast_html.bench` task can be used for running the benchmark by yourself.\n\n| File/Parser          | fast_html (Port) | mochiweb_html (erlang) | html5ever (Rust NIF) | Myhtmlex (NIF)¹ |\n|----------------------|--------------------|------------------------|----------------------|----------------|\n| document-large.html (6.9M)  | 125.12 ms          | 1778.34 ms             | 395.21 ms            | 327.17 ms      |\n| document-small.html  (25K)| 0.50 ms            | 2.76 ms                | 1.72 ms              | 1.19 ms        |\n| fragment-large.html  (33K)| 0.93 ms            | 4.78 ms               | 2.34 ms              | 2.15 ms        |\n| fragment-small.html²  (757B)| 44.60 μs | 42.13 μs | 43.58 μs | 289.71 μs |\n\nFull benchmark output can be seen in [this snippet](https://git.pleroma.social/pleroma/elixir-libraries/fast_html/snippets/3128)\n\n1. Myhtmlex has a C-Node mode, but it wasn't benchmarked here because it segfaults on `document-large.html`\n2. The slowdown on `fragment-small.html` is due to Port overhead. Unlike html5ever and Myhtmlex in NIF mode, `fast_html` has the parser process isolated and communicates with it over stdio, so even if a fatal crash in the parser happens, it won't bring down the entire VM.\n\n## Contribution / Bug Reports\n\n* Please make sure you do `git submodule update` after a checkout/pull\n* The project aims to be fully tested\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdefactosoftware%2Ffast_html","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdefactosoftware%2Ffast_html","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdefactosoftware%2Ffast_html/lists"}