import wixLocation from 'wix-location'; $w.onReady(function () { $w("#html1").onMessage( (event) => { let receivedData = event.data; wixLocation.to(event.data.hospitable_widget_redirect); }); });