The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

Dancer::Plugin::Locale::Wolowitz - Intenationalization for Dancer

VERSION

version 0.121390

SYNOPSIS

    use Dancer ':syntax';
    use Dancer::Plugin::Locale::Wolowitz;

    get '/' => sub {
        template index;
    }

DESCRIPTION

Provides an easy way to translate your application. This module relies on Locale::Wolowitz, please consult the documentation of Locale::Wolowitz.

METHODS

loc

    loc('Welcome');
    loc('View %1', ['Country'])
or
    <% l('Welcome') %>
    <% l('View %1', ['Country']) %>

Translated to the requested language, if such a translation exists, otherwise no traslation occurs.

    input: (Str): Key translate
           (Arrayref): Arguments are injected to the placeholders in the string
    output: (Str): Translated to the requested language

CONFIGURATION

  plugins:
    Locale::Wolowitz:
      lang_session: "lang"
      locale_path_directory: "i18n"

CONTRIBUTING

This module is developed on Github at:

http://github.com/hobbestigrou/Dancer-Plugin-Locale-Wolowitz

ACKNOWLEDGEMENTS

Thanks to Ido Perlmuter to Locale::Wolowitz

BUGS

Please report any bugs or feature requests in github.

SUPPORT

You can find documentation for this module with the perldoc command.

    perldoc Dancer::Plugin::Locale::Wolowitz

SEE ALSO

Dancer Locale::Wolowitz

AUTHOR

Natal Ngétal

COPYRIGHT AND LICENSE

This software is copyright (c) 2012 by Natal Ngétal.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.