xmlview: View, Query, Format, and "Pretty Print" 'HTML'/'XML' Content

> library(xmlview)
> x <- xml2::read_xml("http://www3.city.sabae.fukui.jp/xml/zoo/nisiyamazoo.xml")

バージョン: 0.4.7


関数名 概略
highlight_styles List available styles
renderXmlview Widget render function for use in Shiny
xml_tree_view XML tree viewer
xml_view XML pretty printer & viewer
xmltreeview-shiny Shiny bindings for xmltreeview
xmlview Format and Pretty Print 'HTML'/'XML' Content
xmlviewOutput Widget output function for use in Shiny

highlight_styles

> highlight_styles() %>% {
+   sample(., 5) %>% print()
+   length(.)
+ }
[1] "atelier-estuary-light" "tomorrow-night-bright" "monokai_sublime"      
[4] "idea"                  "agate"
[1] 93

xmlview

Arguments

  • doc
  • style
  • scroll
  • add_filter
  • apply_xpath
  • elementId
  • width
  • height
> xml_view(x)

xmlviewOutput

> xmlviewOutput(x)
> # <div id="&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8...