Group
Extension

Matches 1

Mojolicious-Plugin-HTMX ( G/GD/GDT/Mojolicious-Plugin-HTMX-1.03.tar.gz, GDT, 2024; MetaCPAN )
Mojolicious-Plugin-HTMX/lib/Mojolicious/Plugin/HTMX.pm ( view source; MetaCPAN )
Plugin::HTMX;
use Mojo::Base 'Mojolicious::Plugin';

use Mojo::ByteStream;
use Mojo::JSON qw(encode_json decode_json);
use Mojo::Util qw(xml_escape);

our $VERSION = '1.03';

my @HX_RESWAPS = (qw[
   
r') });

    $app->helper(
        'htmx.req.triggering_event' => sub {
            eval { decode_json(_header(shift, 'Triggering-Event')) } || {};
        }
    );

    $app->helper(
        'htmx.re
    return undef unless $location;

    if (ref $location eq 'HASH') {
        $location = encode_json($location);
    }

    return $c->res->headers->header('HX-Location' => $location);

}

sub _res_

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