I'm not understanding something basic about Kendo templates, so maybe someone can explain this to me. This example of a template for a cell in a grid comes from Telerik sample code.
template:"<input type='checkbox' #= IsAdmin ? checked='checked':'' # />
Ultimately, this produces an input tag which, if the value of IsAdmin is true, will include "checked='checked'"
I don't understand the evaluation context of
#= IsAdmin ? checked = 'checked' : '' #
Documentation says that "#=" indicates "render as literal" (whatever that means), and I understand that "IsAdmin" is a value provided when the template is evaluated/executed.
What follows the #= looks like Javascript, but if it were only that, it would merely set the value of a variable named "checked" to either 'checked' or an empty string.
Is the ? operator here really javascript, or is it Kendo templating language? I've seen no mention of a Kendo-specific language with operators. But if this is truly a Javascript ? operator, how does it work that we get a literal "checked='checked' out of this instead of setting a var named "checked" with value 'checked'.
Call me puzzled.