Filter for buttons is it possible? Help!


I need to filter two buttons like if blue button don’t have a link (to another page) in dataset, so it hide and user will see only red button which linked to product page

Is it possible to do this? Or need some another way?

import wixData from 'wix-data';
import wixLocation from 'wix-location';

$w.onReady(function () {
 function GoToWebsite_click(event, $w) {
 let data = $w("#dataset1").url();
 let buttonLink = $w('#urlB')

 if ( data === buttonLink ) {
        } else {


somebody know how to do this?)))