"Building on that, I’ve used !! quite a bit to coerce values to booleans. Imagine you have a variable that might be a string, a number, null, or undefined. Using !!variable guarantees you get either true or false.
In your example, it’s checking if vertical is defined, then forcing it to be a boolean. This avoids weird cases where, say, "0" or null might behave unexpectedly in conditions. It’s a simple and idiomatic way to clean up data and make sure you’re working with explicit booleans."