Whether an item has a trait. It is also a type guard: after the check the trait's data is typed on the item.
The item to check.
The name of the trait.
Whether an item has a trait. It is also a type guard: after the check the trait's data is typed on the item.