Catalyst::ActionRole::RenderView - Call the default view
package Example::Controller::Root; use Moose; use MooseX::MethodAttributes; extends 'Catalyst::Controller'; sub end : Action Does(RenderView) {}
This is basically Catalyst::Action::RenderView done as an action role (basically a Moose role) rather than as a base class. This is a bit more flexible if you plan to do fancy stuff with your end action.
Two things it doesn't do that the classic Catalyst::Action::RenderView does is it doesn't set a default content type if none is found (old one just set text/html which was probably ok back in the 'Aughts but not always true now) and we don't support the dump_info when in debug mode since I really think something like that belongs in another part of the stack.
text/html
dump_info
I'm willing to be proven wrong, just send me your use cases and patches.
This class can throw the following exceptions which are compatible with CatalystX::Errors
If there's no view found when calling '$c->view()' we throw Catalyst::ActionRole::RenderView::Utils::NoView
John Napiorkowski <jnapiork@cpan.org>
Copyright (c) 2022 the above named AUTHOR
You may distribute this code under the same terms as Perl itself.
To install Valiant, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Valiant
CPAN shell
perl -MCPAN -e shell install Valiant
For more information on module installation, please visit the detailed CPAN module installation guide.