My code is:
template-location 'templates';
route {
after {
template '404.crotmp', hash if .status == 404;
template '500.crotmp', hash if .status == 500;
}
...
and accessing it results in:
Can only use 'template' inside of a request handler
in sub router-plugin-get-configs at /opt/rakudo-pkg/share/perl6/site/sources/BB802F84B227D34EB41F3FA87E22BD753F6E4033 (Cro::HTTP::Router) line 1373
which sounds a bit too restrictive maybe?
My code is:
and accessing it results in:
which sounds a bit too restrictive maybe?