The wire:poll directive provides an easy way to automatically refresh content at regular intervals, keeping your application's data current without requiring user interaction or complex real-time technologies.
Basic Usage
This simple component demonstrates wire:poll with default intervals, custom timing, background polling, and viewport polling:
// wires/PollDemo.bxclassextends="cbwire.models.Component"{ data ={"counter":0,"timestamp":""};functionupdateCounter(){data.counter++;data.timestamp =dateTimeFormat(now(),"HH:mm:ss");}functionupdateStatus(){data.timestamp =dateTimeFormat(now(),"HH:mm:ss");}}