Global templates/2024 MVP
Appearance
This is Tim's idea for a global templates project plan.
Stage 1
[edit]Create the global wiki.
Explicit inclusion syntax.
- Parser function for explicit invocation of a global template, e.g. {{global:foo}}.
- This is a useful feature for piloting and testing. It allows the backend to be decoupled from the import dashboard.
- No narrow task for this yet?
Link tracking and cache invalidation.
Name resolution in the global scope.
- Preprocessing of global templates will occur in the same request as the main parse, however, if you write Template:Foo in a global template, that should only find Template:Foo on the global wiki, not on the local wiki.
- No narrow task yet?
- A similar name resolution feature in Scribunto and TemplateStyles is a requirement at this stage to allow usage of these extensions in global templates.
Template messages.
- Parser function to fetch a message in the content language from a specified on-wiki JSON message bundle, say, {{tmsg:bundle/key|param1|param2}}
- T238411
Stage 2
[edit]Template import special page
- A special page which allows users to select global templates to be available on the local wiki.
- Creating a set of virtual (or real) redirects from e.g. [[Template:Φυυ]] to [[global:Template:Foo]].
- Title and parameter name mappings fixed at the time of import, saved into the local DB.
- Tracked in a new local table with changes conventionally logged.
- I haven't found any task or document for this, but the requirement emerges from Amir's stated goals.
Action overrides for imported templates.
Consequent extension updates (VisualEditor, TemplateWizard etc.)
Stage maybe
[edit]Things that would be nice to have but are not strictly necessary for the MVP:
- A translation UI.
- Globally configured title and parameter name localisation.
- VisualEditor support for explicit global inclusion.
- Scribunto require(‘global:foo’) T243931, T41610.
- Scribunto binding for the message bundle feature, say mw.message.newFromBundle() T238341
- Local overrides
User-language messages
- Migration tool (T245737)
- Citoid integration
Not right now
[edit]- Semantic content blocks (T103630)