* Owen Davis owen@wikia-inc.com [Wed, 21 Dec 2011 19:18:46 +0000 (UTC)]:
It is littered with embedded HTML and string.format statements. Ugh. I'm going to look at something simple like Moustache (which has both JS and Lua implementations already) as a proof of concept. Does anybody have a better suggestion? I think Lua (or JS) by itself is
not
enough, there has to be a nice library of utility functions. Has
anyone
thought about what that will really look like?
My guess that scripts interpreter should have MediaWiki API bindings: http://www.mediawiki.org/wiki/Api and Wiki DOM bindings, either something like already existing extension: http://www.mediawiki.org/wiki/Extension:Wiki_Object_Model or, even better WikiDOM manipulation: http://www.mediawiki.org/wiki/Visual_editor/WikiDom_Specification when the PEG Parser will be stable enough.
Building an API wrapper around Lua http client probably is not enough, because local API should be performed through FauxRequest (but still no POST emulation?). I don't know how PHP and Lua can bind to each other. I know a local pro in Lua working in local uni CS lab, however he does not work with MediaWiki. Lua is used for macros and automation in C / C++ projects. Dmitriy