Conditions work almost everywhere.
dmx-bind:href="var1.value == 'yes' ? 'https://some.url' : 'https://someother.url'"
What you can’t do is call JS functions in dmx. Anywhere.
So you need to create a function separately>
function goBack(){ javascript:history.back() }
And then NOT use href, and instead use dmx-on:click
.
Here, use a flow to set the same condition and use RUN step for regular url browser.goto
and RUN JS step to call goBack
JS function.