Skip to content

Instantly share code, notes, and snippets.

@marcusramberg
Created December 19, 2011 09:46
Show Gist options
  • Save marcusramberg/1496358 to your computer and use it in GitHub Desktop.
Save marcusramberg/1496358 to your computer and use it in GitHub Desktop.
~ $ perl -MMojo::DOM -le'Mojo::DOM->new("<body><div>foo<div>bar</div></div></body>")->find("body > div")->each(sub {print shift->text})'
foo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment