You are viewing a single comment's thread from:

RE: Programming Diary #26: Displaying voting power on Steemit.com and other condenser sites

in #javascript2 months ago (edited)

Is that section needed for Firefox?

The host_permissions should ensure that the fetching of data from these sources is permitted. The servers used should therefore be included there.
However, there is a difference between Firefox and Chrome. Firefox complains about violation of CORS guidelines, while Chrome runs the extension without any problems.
I've just thought of something I need to check.

Something else occurred to me this morning: We don't actually need the mutation loop at all. When mutations are done, we can only look for the usermenuDropdown element and continue working with it if it exists. We don't have to go through the individual mutations at all.

By the way, I actually wanted to write yesterday that the idea of the MutationOberserver was very brilliant!
What I forgot yesterday at a late hour: The disconnect should not be done, otherwise the MutationOberserver will not register the changes when logging off and on again.

Update:
Firefox cannot be persuaded to ignore the CORS policies of the Condenser for the extension. I will add the domain sds.steemworld.org to the CORS policies on my server next time.

Sort:  

I merged your changes into my branch the other day, and then merged into main tonight. Thank you very much. The solution without looping is a huge improvement!

By the way, I actually wanted to write yesterday that the idea of the MutationOberserver was very brilliant!

I wish I could take credit, but it came from one of the AIs. Claude, I think, but maybe ChatGPT. I didn't even know that mutation observers existed before that. My part was just stumbling into the right question. ;-)

The host_permissions should ensure that the fetching of data from these sources is permitted.

Yeah, that's how I understood it, but my browser doesn't seem to care whether those settings are actually there or not. I left them in, and added justyy's load balancer, too - just in case we want to use them later. I'm still not clear on why it doesn't really seem to be needed in Brave, though.