Loading States
Toggling Elements
// File: ./wires/Cart.cfc
component extends="cbwire.models.Component"{
function checkout(){
sleep( 5000 ); // optimize this code yo!
}
function $renderIt(){
return this.$renderView( "wires/cart" );
}
}// File: ./views/wires/cart.cfm
<div>
<button wire:click="checkout">Checkout</button>
<div wire:loading>
Processing Payment...
</div>
</div>Toggling Attributes
Delay Loading State
Display Property
Hide During Loading State
Last updated
Was this helpful?