Dancer2::Plugin::UnicodeNormalize - Normalize incoming Unicode parameters
Version 0.04
use Dancer2::Plugin::UnicodeNormalize;
Dancer2::Plugin::UnicodeNormalize normalizes all incoming parameters to a given normalization form. This is achieved with a before hook, which should run silently before processing each route. By default, we use Unicode Normalization Form C - this is usually what you want. Other forms can be selected, see: "CONFIGURATION".
This plugin was inspired by Mojolicious::Plugin::UnicodeNormalize. For information on why Unicode Normalization is important, please see:
http://www.perl.com/pub/2012/05/perlunicookbook-unicode-normalization.html
http://www.modernperlbooks.com/mt/2013/11/mojolicious-unicode-normalization-plugin-released.html
plugins: UnicodeNormalize: form: NFC exclude: - '^/(css|javascripts|images)'
The form parameter is described in Unicode::Normalize. Default is NFC.
form
The exclude parameter consists of a list of regular expressions to match routes we do not wish to process parameters for.
exclude
John Barrett, <john@jbrt.org>
http://github.com/jbarrett/Dancer2-Plugin-UnicodeNormalize
All comments and contributions welcome.
Please direct all requests to http://github.com/jbarrett/Dancer2-Plugin-UnicodeNormalize/issues or email <john@jbrt.org>.
Copyright 2013 John Barrett.
This application is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
Dancer2
Unicode::Normalize
Mojolicious::Plugin::UnicodeNormalize
To install Dancer2::Plugin::UnicodeNormalize, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Dancer2::Plugin::UnicodeNormalize
CPAN shell
perl -MCPAN -e shell install Dancer2::Plugin::UnicodeNormalize
For more information on module installation, please visit the detailed CPAN module installation guide.