-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
do not overwrite the default handler #1
Comments
Hi, You are absolutely right; the plugin should work this way :) I dont really like checking for presence, its unneeded overhead 80% of the time (you normally use just 1 templating system). Statting the filesystem should be last resort as its a scaling and performance issue. Apart form that, your fix works great. I primarily see three approaches:
And I dont really like any of them, and number 4 I dont know if is very doable at all. |
i think it should be like:
i don't know if this sounds reasonable, i tried to cover the major use-cases. |
i'm new to li3 so please forgive me if i overlooked something, but i installed both li3_twig and li3_docs plugins and after activating twig everything disappeared as it replaces the default handler (when registering the media type in boostrap). i created a short workaround to be able to use the old default config and use twig if a template is presented, however i think the right approach would be to get the View/Media check the presented templates, eg. one could register multiple templating engines and the View/Media should pick the right one (based on preference and presence). i'm not sure where to stick this logic and how to make the configuration convenient. another point would be to support mixed types (eg. simple php layout with twig template).
The text was updated successfully, but these errors were encountered: