Did you know Nokogiri now has opt-in HTML5 parsing?

This page summarizes the projects mentioned and recommended in the original post on /r/ruby

Judoscale - Save 47% on cloud hosting with autoscaling that just works
Judoscale integrates with Rails, Sidekiq, Solid Queue, and more to make autoscaling easy and reliable. Save big, and say goodbye to request timeouts and backed-up job queues.
judoscale.com
featured
InfluxDB high-performance time series database
Collect, organize, and act on massive volumes of high-resolution data to power real-time intelligent systems.
influxdata.com
featured
  1. Nokogiri

    Nokogiri (鋸) makes it easy and painless to work with XML and HTML from Ruby.

    RFC: Explore alternatives to libxml2 for HTML parsing · Issue #2064 · sparklemotion/nokogiri, the original discussion that ended with the decision to merge Nokogumbo into Nokogiri

  2. Judoscale

    Save 47% on cloud hosting with autoscaling that just works. Judoscale integrates with Rails, Sidekiq, Solid Queue, and more to make autoscaling easy and reliable. Save big, and say goodbye to request timeouts and backed-up job queues.

    Judoscale logo
  3. Ruby on Rails

    Ruby on Rails

    I noticed this existed because of recent This Week in Rails (official reails newsletter from Rails team), which mentioned Rails PR Update Action View to use HTML5 standards-compliant sanitizers, which then mentioned that Nokogiri now has opt-in Rails5 parsers (Cruby-only, not supported on JRuby).

  4. loofah

    Ruby library for HTML/XML transformation and sanitization

    loofah and rails-html-sanitizer gems follow nokogiri's lead to have opt-in HTML5 parsing (using nokogiri), using HTML5 classes -- if you use the default existing legacy API, you still get HTML4 parsing.

  5. rails-html-sanitizer

    loofah and rails-html-sanitizer gems follow nokogiri's lead to have opt-in HTML5 parsing (using nokogiri), using HTML5 classes -- if you use the default existing legacy API, you still get HTML4 parsing.

  6. rails-dom-testing

    Extracting DomAssertions and SelectorAssertions from ActionView.

    Switching to HTML5 parsing for everything is a very good idea, but in a lot of cases it's not straightforward because -- blurgh -- people tend to write unit tests that assert on the exact output string. Currently Discourse is dealing with this, and I've started work to upgrade Mastodon and am hitting similar problems. (Worth noting that Rails provides a test helper, assert_dom_equals, that should cover the majority of use cases.)

  7. InfluxDB

    InfluxDB high-performance time series database. Collect, organize, and act on massive volumes of high-resolution data to power real-time intelligent systems.

    InfluxDB logo
NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • The Mythical IO-Bound Rails App

    3 projects | news.ycombinator.com | 25 Jan 2025
  • Introducing the `script` Folder in Rails 8 and a New Gem for Browser-Based Data Migration

    4 projects | dev.to | 20 Dec 2024
  • Optimizing Ruby's JSON, Part 1

    9 projects | news.ycombinator.com | 18 Dec 2024
  • Nokolexbor: Drop-in replacement for Nokogiri. 5.2x faster at parsing HTML

    4 projects | news.ycombinator.com | 17 Nov 2024
  • How we made a Ruby method 200x faster

    4 projects | news.ycombinator.com | 17 Nov 2024

Did you know that Ruby is
the 12th most popular programming language
based on number of references?