How does the negative (not) conditional work in Twig?
Twig != is a comparison operator.


  The following comparison operators are supported in any expression: ==, !=, &lt;, >, >=, and &lt;=


You can use != to compare any two things that php lets you compare, and what you get back is a boolean.

Twig not is a logic operator. (so are and and or)


  not: Negates a statement.