Skip to main content
4 events
when toggle format what by license comment
Apr 9, 2016 at 0:03 comment added Gerold Broser More performant? For sure? More or less deeply nested and chained substr[ing]()s and [last]indexOf()s are harder to read for me. I don`t consider them being concise. There are various indent styles. I usually use Whitesmiths. If it is to save vertical space: Ratliff. Or the one that has been agreed on in a project I'm working on together with others. I always consider "Choose one, than stick to it." for each of my projects.
Apr 8, 2016 at 23:34 comment added Quill Perhaps string functions would be better @GeroldBroser, they may even be more performant. The closing brace belongs on the same level of indentation as the function declaration
Apr 8, 2016 at 23:06 comment added Gerold Broser Thanks for the reply! Where do you think that the closing brace belongs to? If one reads the whole function header addLinksTo(tags) and call addLinksTo(rTags) it's clear "where to" and "in what" respectively, isn't it? rTag, aTag, iTag, uTag refer to related, active, interesting, unanswered as mentioned in comments directly above. And since these are solely used in the immediate context of the next few lines... But you're right. I usually prefer good descriptive names as well. What do you suggest for extracting strings concisely instead of Regex? String's functions?
Apr 8, 2016 at 22:02 history answered Quill CC BY-SA 3.0