[][src]Function hatter::builtin::when

pub fn when(args: Args<'_>) -> Result<Value>

Returns a Value if a condition is true. Used internally by tag attributes.

This example is not tested
when(true, "yep")   #=> "yep"
when(false, "nope") #=> None