to write a custom formatter, in our
case a JSONL formatter.
=head1 DESCRIPTION
This tutorial explains a minimal formatter that outputs each event as a json
string on its own line. A true formatter w
package Test2::Formatter::MyFormatter;
use strict;
use warnings;
use JSON::MaybeXS qw/encode_json/;
use base qw/Test2::Formatter/;
sub new { bless {}, shift }
sub encod
ite {
my ($self, $e, $num, $f) = @_;
$f ||= $e->facet_data;
print encode_json($f), "\n";
}
1;
=head1 LINE BY LINE
=over 4
=item use base qw/Test2::Formatter/;
All