Skip to content

Commit

Permalink
a few more node navigation examples
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Nov 26, 2014
1 parent 881d719 commit e354d03
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions lib/Mojo/DOM.pm
Expand Up @@ -684,6 +684,10 @@ more siblings.
$dom->parse('<p><b>123</b><!-- Test -->456</p>')->at('b')
->next_sibling->next_sibling;
# " Test "
$dom->parse('<p><b>123</b><!-- Test -->456</p>')->at('b')
->next_sibling->content;
=head2 node
my $type = $dom->node;
Expand Down Expand Up @@ -759,6 +763,10 @@ no more siblings.
$dom->parse('<p>123<!-- Test --><b>456</b></p>')->at('b')
->previous_sibling->previous_sibling;
# " Test "
$dom->parse('<p>123<!-- Test --><b>456</b></p>')->at('b')
->previous_sibling->content;
=head2 remove
my $parent = $dom->remove;
Expand Down

0 comments on commit e354d03

Please sign in to comment.