Updating browser source with javascript

Devo Spice

New Member
I'm creating an overlay with a simple browser app that has text that I need to update periodically. I did a test a while ago and I thought I had it working so whenever I changed the contents of the page with javascript the browser input updated accordingly, but now I can't get it working.

The weird thing is the javascript works if it runs on load, but anything that is triggered by user input doesn't appear to work. I put a circle on the page and used a setInterval function to make it move across the page onLoad and that worked fine. Also, changing the innerHTML of a P tag works if I use a setTimeout after the page loads. But I added some buttons to the page to change that same text and while it updates in the browser OBS's browser source never does. Calling those functions from the console also updates the page but not OBS.

I'm running OBS 26.1.2 on a 2016 MacBook Pro running Catalina (10.15.7). Any ideas?
 
Top