3 ms·
You have a weird perception of English. "If the tab is selected, the CSS class is 'selected', else it's deselected. Or in pseudocode if isCurrentTab
by Cthulhu_ 5y ago
You have a weird perception of English. "If the tab is selected, the CSS class is 'selected', else it's deselected.
Or in pseudocode
if isCurrentTab
cssClass = 'selected'
else
cssClass = 'deselected'
Even ternaries read weird. "css class is current tab HUH?? selected COLON! deselected"
- chrismorgan 5y ago“Set css class to ‘selected’ if it’s the current tab, or else ‘deselected’.”
- QuadrupleA 5y agoBoth read grammatically fine to me. If you prefer to do things in 4 lines rather than one, and repeat the variable, that's up to you I guess - a lot of people seem to agree - but honestly I don't get what the fuss is about.