has_children: Wether children nodes exist

Description Usage Arguments Value Examples

View source: R/children_node.R

Description

Wether children nodes exist

Usage

1

Arguments

...

one or more documents, nodes, or node sets.

Value

logical value

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
txt='<div class="activityBody postBody thing">
        <p>
            <a href="/forum/conversation" rel="post" >(22)</a>
            where?
        </p>
      <p>
        stays 
        <b>disappears</b>
        <a>disappears</a>D
        <span>disappears</span>
        stays
      </p>
    </div>'
 library(xml2)
 html=read_html(txt)
 has_children(html)

do documentation built on July 16, 2021, 9:08 a.m.