Hello, please help me hide the “STATEBOX” in a dynamic page if there is no content. It shows an empty box when there is no data to show from dataset. Thank you for your help.
What content should be there in case it exists (how does it appear in the database, what field keys? image? text?)?
Is this box in a repeater item or regular (non-repeater) element?
$w.onReady(() => {
$w('#dynamicDataset').onReady(() => {
const item = $w('#dynamicDataset').getCurrentItem();
if(!item?.title /*for example. Let say you're interested in the title field existence*/){
$w('#box').collapse();
}
})
})