I tried to call a Javascript function with Callback Handler="{someJSFunction}" but the console always says {someJSFunction} not found in data context.
My Code:
<JavaScript>
console.log("test");
function someJSFunction () {
console.log("some function called");
}
module.exports = { someJSFunction: someJSFunction };
</JavaScript>
<Callback Handler="{someJSFunction}"/>
Why would you put JavaScript inside of Clicked? Don’t do that.
The JavaScript block is instantiated in UX, so if you only have it there while the Clicked trigger is active (which is a very short while, since it’s a pulse trigger), then it’s no wonder it doesn’t work.
Perhaps you should familiarise yourself with MVVM pattern, since that is what you should follow when making Fuse apps.