how to conditionaly add class to element react code example Example: conditional classname prop react <span className={todo.completed ? "true" : ""}>