diff options
author | http://smcv.pseudorandom.co.uk/ <smcv@web> | 2013-09-16 05:02:40 -0400 |
---|---|---|
committer | admin <admin@branchable.com> | 2013-09-16 05:02:40 -0400 |
commit | 44750efde83007e3d346ceff35e5896d36e8c355 (patch) | |
tree | 6969189acec182ef1fb18697e78ee3fd01f34c08 | |
parent | 96067ffdf2cdbabf40c0246f5cd55c3421f84dd2 (diff) | |
download | ikiwiki-44750efde83007e3d346ceff35e5896d36e8c355.tar ikiwiki-44750efde83007e3d346ceff35e5896d36e8c355.tar.gz |
response
-rw-r--r-- | doc/bugs/template_creation_error.mdwn | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/doc/bugs/template_creation_error.mdwn b/doc/bugs/template_creation_error.mdwn index 03641dd5b..f1751ab30 100644 --- a/doc/bugs/template_creation_error.mdwn +++ b/doc/bugs/template_creation_error.mdwn @@ -158,3 +158,29 @@ Please, let me know what to do to avoid this kind of error. >>> the directive? >>> >>> --[[chrysn]] + +>>>> Thanks for your feedback! +>>>> Looking at its description on this wiki, I agree that `type/web` doesn't +>>>> fit, and core does seem better. I like your `templatebody` suggestion, +>>>> too, particularly if templates remain restricted to `/templates`. +>>>> I'll try to come up with better wording for the documentation to say +>>>> "use `templatebody`, like this", with a note about backwards +>>>> compatibility later. +>>>> +>>>> Rationale for `my %templates`: yes it does seem a bit odd, but +>>>> if I used `$pagestate{$tpage}{template}` instead of a `my` variable, +>>>> I'd sometimes _still_ have to force a `scan`, because +>>>> [[plugins/template]] has to expand the template at scan time so that +>>>> it can contain links etc. - so I have to make sure that if the +>>>> template has changed, it has already been scanned (scanning happens +>>>> in random order, so that can't be guaranteed). This means there's +>>>> no benefit in reading it back from the index, so it might as well +>>>> just be in-memory. +>>>> +>>>> I suppose an alternative way to do it would be to remember what was +>>>> passed to `needsbuild`, and only force a `scan` for templates that +>>>> were in that list - which potentially reduces CPU time and I/O a +>>>> little, in exchange for a bigger index. I could do that if Joey +>>>> wants me to, but I think the current approach is simpler, +>>>> so I'll stick with the current approach if it isn't vetoed. +>>>> --[[smcv]] |