Als try to resolve partials relative to the containing template #25

Merged
merged 1 commit into from Apr 14, 2012

Conversation

Projects
None yet
2 participants
@pepve
Contributor

pepve commented Apr 12, 2012

I wrote some code to also try to resolve a partial relative to the directory the referencing template is in. I also added a test file to test this behaviour, and made sure there are no regressions. (It however may cause some partials to resolve that would previously just show up as errors.)

I need this because I am serving up different sets of templates (with different 'roots') for different requests. So I can not use the mu.root setting. But invoking Mu with an absolute filename and relying on relative partials (this commit) works very well.

Pepijn Verlaan
partials can now also be resolved relative to the containing template…
…, this makes using Mu without setting the global root and just using absolute paths easier

@raycmorgan raycmorgan merged commit 4aad0f9 into raycmorgan:master Apr 14, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment