Thread:DoCheonGong/@comment-26235098-20150826215146/@comment-26235098-20150827160303

Excellent! :)

Yes... I see you are splitting the difficulty always ... that is something to think about.

There is an existing problem in the List of levels with this, because when there is a split difficulty, it doesn't automatically show up (it can't, because it has to be called separately). So this is not a new problem. It is almost impossible to send back something which will split a cell, because depending how the entry is formatted (wikitable cell, or html table, or div or span) it is pretty hard to pre-package something that will return an appropriately split display element.

I will think about this too... I have written code here and there to detect split... maybe I can find generalize the "split detection" through a template. Then individual situations will still have to test this and display accordingly.

Part of the issue here is that often the code uses templates that ultimately call Difficulty level, and this gets expensive, especially on things like List of levels. Looking up a level once or twice in a 1000+ line table is very fast, but often this call is repeated multiple times for one level (because we cannot save state variables in transformational languages like markup). On a single level page, it's no problem. On a list of levels... now we are processing a 1000+ line table may 5 times PER level... so we are doing that over 1000 times -- it adds up.

So this is my main concern -- not so how to do this... but how to do it efficiently.