I am using code like this:
JS_EvaluateScript(context, global,"go_back('blabla')", 17, "", 1, &R);
to call go_back()
, which is already in the context
. But this is extremely slow, and I think because the string have to be compiled each time.
I try to find the way to call the same piece of code many times in a fast way, without recompilation, or some object creation each time. But Mozilla docs and sources are not organized that way, there is only a reference, and you need to know every function before you can make any choice.
So any hints? What would be the best practice for this?