Page MenuHomePhabricator

Investigate possibility of using a JS/PHP template engine for rendering DataValue
Closed, ResolvedPublic


Using a template engine which can then be used in PHP as well as in JavaScript, allowing us to define snippets of HTML with basic logic/placeholders.

A engine suited for our needs had to be chosen, it had to be investigated whether any options are already used by other MediaWiki extensions so we could re-use or integrate into core or a separate extension (The actual implementation should probably be done with a resource loader module).

This would move a lot of code out of the EntityView classes, the HTML wouldn't have to be generated with the static Html class, which would look a lot prettier and less confusing since the whole markup could just be written as such.

Version: unspecified
Severity: normal



Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 1:08 AM
bzimport set Reference to bz40886.
bzimport added a subscriber: Unknown Object (MLST).

Instead of using a full blown engine, the HTML will be created in the server and then given to the client via a ResourceLoader resource. This means that it is not required to be able to create snippets from templates.