To make graphs trully convinient to write and edit, we should create a Special:GraphSandbox, where editors can dynamically experiment with the graphs without saving/page previewing them. This could be a fairly easy student project.
Currently this code is partially implemented and works as part of the Graph: namespace, but the graph namespace is only available in mediawiki.org and a few other sites. I do not plan to add Graph: ns to other wikis, as it is much less convinient compared to template approach. To see it work, open any Graph: ns page on mediawiki.org, and page preview it - graph will update as you type.
Current implementation:
- https://www.mediawiki.org/w/index.php?title=Graph:Sample&action=edit
- Click "preview"
- changing graph width should show up right away
Needed features:
- graph is updated on each keystroke
- ability to enter graph template parameters
- dynamic template parameter resolution
- At this point, we can simply resolve parameters in the form of {{{1}}}, {{{name}}}, {{{1|default}}}, etc
- Eventually, it would be awesome to use parser api to resolve everything, e.g. {{{#if ... }}}