Javascript on the fly with components

Hello. Is there any way to “inject” javascript and attach it to a component “live” in order to change its behavior? For example, I would like a link_button component to open a new tab when clicked but also do something else at the same time, without triggering a re-run. In my scenario, I present a series of link_buttons and would like to track what logged in user clicked on what link (and record that, e.g. in an AWS bucket). I don’t want to use a button with a callback (or inside an if st.button()) block because that causes a rerun and it in turn screws up my whole screen (ghosting and all).

Thanks!

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.