What does the !! (double exclamation mark) operator do in JavaScript
The !! operator reassures the lint tool that what you wrote is what you meant: do this operation, then take the truth value of the result. A third use is to produce logical XOR and logical XNOR.