From Code to Community: Sponsoring The Perl and Raku Conference 2025 Learn more

use strict;
use URI;
sub scrape {
my $res;
my $emoji = scraper {
process '//table[@width="100%" and @cellpadding="2"]//tr/td/font/../..',
'emoji[]' => scraper {
process '//td[2]/font', unicode => 'TEXT';
process '//td[3]/font', sjis => [ 'TEXT', sub { unpack "H*", shift } ];
};
result 'emoji';
};
foreach my $url (@urls) {
push @$res, @{ $emoji->scrape( URI->new($url) ) };
}
$res;
}
1;