Example : deleting a file by a button. While fetch is quering, qe can add the btn-loading class, but if error, we could be able to add a class btn-error and then, with tabler-icon, show a exclamation mark.
But this shouldnt habe anything to do with a button. It should be e.g. an icon that could be placed AS HTML content anywhere. In a button, after a btn, in a Combo box, after a link, in a toast etc.