Injecting JS?

Not sure if it solves your issue, but maybe you have to wait until the page is loaded before you can access the element:

I also wrote a custom component to run javascript: Streamlit-javascript, run client side javascript and get result - #2 by andfanilo

2 Likes