HTML::MasonX::Free::Compiler - an HTML::Mason compiler that can reject more input
version 0.007
This is an alternate compiler for HTML::Mason. It's meant to fill in for the default, HTML::Mason::Compiler::ToObject. (Don't trust things telling you that the default is HTML::Mason::Compiler. If you're using Mason, you're almost certainly have ToObject doing the work.)
By default, it should behave just like the normal compiler, but more options can be provided to make it stricter.
Right now, there's just one extra option, but there will be more.
This library should run on perls released even a long time ago. It should work on any version of perl released in the last five years.
Although it may work on older versions of perl, no guarantee is made that the minimum required version will not be increased. The version may be increased for any reason, and there is no promise that patches will be accepted to lower the minimum required perl.
If false, any text outside of a block (like a method or doc block), other than blank lines, will be fatal. Similar, any Perl lines other than comments will be fatal.
If set, this is the name of a method that will be dropped in place whenever the user is trying to call a component without a method. For example, if you set it to "main" then this:
<& /foo/bar &>
...will be treated like this:
<& /foo/bar:main &>
To keep this consistent with the top-level called performed by the mason interpreter, you should probably also use HTML::MasonX::Free::Component as your component class.
Ricardo Signes <cpan@semiotic.systems>
This software is copyright (c) 2022 by Ricardo Signes.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install HTML::MasonX::Free, copy and paste the appropriate command in to your terminal.
cpanm
cpanm HTML::MasonX::Free
CPAN shell
perl -MCPAN -e shell install HTML::MasonX::Free
For more information on module installation, please visit the detailed CPAN module installation guide.