Create a named list (indexed by xpath) of the final computed style for each element

css_apply(xml, css = list(), svg = FALSE)

Arguments

xml

xml document as returned by xml2::read_html() or xml2::read_xml()

css

list of rules parsed from CSS stylesheet. E.g as returned by cssparser::read_css()

svg

include SVG presentation tags in the cascade? default: FALSE

Value

named list of styles where the name is the xpath to a node in the document, and the value is a named list of property/values for this element.