Need help on Routing: Unable to run script on content page

I think you need to add a page flow, and inside of it under execute add Run Javascript.
Set your click event to to call that flow’s run command.

I think.
See: Can we execute a custom script function in Wappler?

Disclaimer I’ve not yet dove into app flow and page flow yet. So there’s that.