assert

abstract fun assert(condition: Boolean = definedExternally, vararg data: JsAny?)(source)

The console.assert() static method writes an error message to the console if the assertion is false.

MDN Reference