Ruby nokigiri

From wikinotes
Revision as of 20:01, 14 September 2021 by Will (talk | contribs) (→‎Documentation)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

nokigiri is an html parser

Documentation

website https://nokogiri.org/
require 'nokigiri'

html = '<html><title>foo</title></html>'
doc = Nokigiri::HTML.parse(html)
doc.css("title")  # css-select elements