Board Thread:New Features/@comment-24739709-20150518230347/@comment-24473195-20150715082918

Mark Otaris wrote: Right now, I use InfoboxBuilder because it allows me to have a Lua module with complicated code with which I can do things it is impossible to do with parser functions. You can see an example of what I'm doing at c:roblox:Module:GroupInfobox. I completely wholeheartedly agree. But because I'm such a lazy guy I've never bothered to create a better solution. For example, if you look at w:c:Duolingo:Template:Courseinfobox  you'll note that it is automatically generated. With zero intervention from users, I used a very inefficient hack to generate each field, and it probably ends up making the page take longer to load.

Therefore, I see two ways to go about this: maintaining InfoboxBuilder and making it work on mobile devices, or creating a Scribunto library that makes it possible to create infoboxes transparently from Lua modules. The second suggestion would mean, for example, creating a  library which could be used to create an   object which could have methods for adding fields, headers, labels, values, etc. to the infobox. Then, using the  function on the infobox object could generate the wikitext with the XML tags and everything else, as it does with the   library. This would be really neat, better than continuing to support InfoboxBuilder and more consistent since there would be only one way to do infoboxes, but it might require more work than the other option. Again, I agree, it could even be merged upstream and MediaWiki employees could further improve upon it.

There's just one thing I disagree, loading modules from dev.wikia is not as painful as it used to be, using:

local potBoxes = require("Dev:Utility")

The code above would automatically load the module from dev.wikia for any wikia to use. Although it would probably be better if the parserfunction would use internal lua logic to generate its code.

The fact that we now have global modules means that we can collaborate and develop better overall modules. Although there needs to be a way of tracking this, and I've already suggested it to wikia support.

In the end, I don't think it is possible to keep these templates clutterfree and clean without using scribunto. It would also not make much sense considering that eventually the aim is to populate some templates using data from wikidata, and this is too painful or nigh impossible to do without scribunto/javascript.

This is also a center of attention at the upcoming wikimania,Extension:Capiunto/Infobox.

P.S. Perhaps you should upload your module to dev.wikia, we have been maintaining a repository of modules there.