[Catalyst-dev] Catalyst::View::TT and PROVIDERS
Andreas Marienborg
omega at palle.net
Mon Apr 28 12:09:14 BST 2008
Hello
I try to use Template::Provider::Encoding, to make usage of utf-8
encoded templates easier. The problem is that to make it work nicely,
I need to do something with Catalyst::View::TT. The issue is that I
need to tell the PROVIDER about INCLUDE_PATH, but the INCLUDE_PATH
gets set after all the PROVIDERS are done initializing, and thus any
$c->stash->{additional_template_paths} gets lost.
I have created a patch (attached) that extends the View::TT PROVIDERS
config-key a bit, and also reorders the constructor a little.
The net benefit is that the PROVIDER initialization code now can copy
config-keys from the main config, and when it copies INCLUDE_PATH, it
copies the one with the coderef, which ends in
additional_template_paths working when I use the Encoding-provider.
- andreas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: catalyst-view-tt-reorder.diff
Type: application/octet-stream
Size: 5362 bytes
Desc: not available
Url : http://lists.scsys.co.uk/pipermail/catalyst-dev/attachments/20080428/d5aadf0b/catalyst-view-tt-reorder.obj
-------------- next part --------------
More information about the Catalyst-dev
mailing list