Group
Extension

Matches 4

Template-Flute ( H/HO/HORNBURG/Template-Flute-0.027.tar.gz, HORNBURG, 2021; MetaCPAN )
Template-Flute/lib/Template/Flute/Iterator/JSON.pm ( view source; MetaCPAN )
JSON;

use strict;
use warnings;

use JSON;

use base 'Template::Flute::Iterator';

=head1 NAME

Template::Flute::Iterator::JSON - Iterator class for JSON strings and files

=head1 SYNOPSIS

    $json
pg"}
    ]};

    $json_iter = Template::Flute::Iterator::JSON->new($json);

    $json_iter->next();

    $json_iter_file = Template::Flute::Iterator::JSON->new(file => 'fruits.json');

=head1 DESCRIP
:Flute::Iterator::JSON is a subclass of L<Template::Flute::Iterator>.

=head1 CONSTRUCTOR

=head2 new

Creates an Template::Flute::Iterator::JSON object from a JSON string.

The JSON string can be eit
Template-Flute ( H/HO/HORNBURG/Template-Flute-0.027.tar.gz, HORNBURG, 2021; MetaCPAN )
Template-Flute/lib/Template/Flute/Filter/JsonVar.pm ( view source; MetaCPAN )
ackage Template::Flute::Filter::JsonVar;

use strict;
use warnings;

use base 'Template::Flute::Filter';
use JSON;

=head1 NAME

Template::Flute::Filter::JsonVar - JSON to Javascript variable filter

structure or a JSON string and returns Javascript
which parses the JSON string with Jquery and assigns it to
the variable C<json>.

The following example shows you how to inject the JSON variable
into
t/javascript" id="vars"></script>

XML Specification:

    <value name="jsvars" id="vars" filter="json_var"/>

Values for L<Template::Flute>:

    Template::Flute->new(...,
        values => {jsvars =
Template-Flute ( H/HO/HORNBURG/Template-Flute-0.027.tar.gz, HORNBURG, 2021; MetaCPAN )
Template-Flute/lib/Template/Flute/Iterator.pm ( view source; MetaCPAN )
 License as published
by the Free Software Foundation; or the Artistic License.

See http://dev.perl.org/licenses/ for more information.

=head1 SEE ALSO

L<Template::Flute::Iterator::JSON>

=cut

1;
Template-Flute ( H/HO/HORNBURG/Template-Flute-0.027.tar.gz, HORNBURG, 2021; MetaCPAN )
Template-Flute/lib/Template/Flute.pm ( view source; MetaCPAN )
anguageName>.
Requires L<Locales> module.

=item json_var

JSON to Javascript variable filter, see L<Template::Flute::Filter::JsonVar>.
Requires L<JSON> module.

=item lower_dash

Replaces spaces with
ix.

Thanks to Jeff Boes for spotting a typo in the documentation of the
Template::Flute::Filter::JsonVar class.

Thanks to Ton Verhagen for being a big supporter of my projects in all aspects.

Thank

Powered by Groonga
Maintained by Kenichi Ishigaki <ishigaki@cpan.org>. If you find anything, submit it on GitHub.