e Yeb::Plugin::GeoJSON;
BEGIN {
$Yeb::Plugin::GeoJSON::AUTHORITY = 'cpan:GETTY';
}
# ABSTRACT: Yeb Plugin for GeoJSON response with Geo::JSON::Simple functions
$Yeb::Plugin::GeoJSON::VERSION = '0.00
3';
use Moo;
use Geo::JSON::Simple;
has app => ( is => 'ro', required => 1 );
sub BUILD {
my ( $self ) = @_;
$self->app->register_function('geojson',sub {
my $object = shift;
$self->app-
>cc->content_type('application/json');
$self->app->cc->body($object->to_json);
$self->app->cc->response;
});
for my $func (@Geo::JSON::Simple::EXPORT) {
$self->app->register_function($