Open khanc opened 9 years ago
I have the same problem with some pages from github. for example https://github.com/realm/realm-java/pull/1214 The firefox will freeze and pop up a dialog to say there is no response from script itsalltext.js:251 (or line 41.)
I've got a similar problem with an internal page of mine, but it's obviously because there are hundreds of text boxes, and it just takes the plugin a long time to process them all.
If I could blacklist pages so that the processing doesn't occur, I'd be happy. Then I could still use the right-click menu option to manually start the plugin if I really needed to.
Optionally, the plugin could see that there's more than X textboxes, and ask 'are you sure you want these processed? It'll be slow!'
I like the idea of saying "There are more than X textareas, not running IAT on this page." X would be configurable via the preferences.
+1.
This might be the very same problem I'm seeing with long issue lists n GitLab. Firefox even starts to complain whether it should stop the script cacheobjs.js (iirc the name).
Will try to look at the code an see if there's a simple solution.
@exaexa: Great! I'll happily accept a pull request for just the feature without the preference. I can add the preference later. I'm not sure what the limit (by default) should be. I imagine it depends highly on the platform.
Alternatively, if you can get the profiler to run and give good metrics, we could try to fix whatever is being slow.
Or both.
Another suggestion: add a preference to toggle so that itsalltext only processes a textbox once it gets focus, instead of processing all textboxes preemptively.
If I could figure out how to do that, then that feature would be on all the time.
The problem is that not all textarea
s have @id
attributes, so I can't "address" a specific textarea
reliably if I don't attach a cacheobj
immediately.
I'm not sure if newer changes in FF have anything that could make this work better, it's hard to wade through all the changes looking for something that might let me re-architect how IAT works.
Ah, I didn't realise this problem. I naïvely thought you could just listen for a click in "all" textareas on a page, and in the triggered event figure out how to address this textarea, and then process it. My JS is weak.
It's one of those things that is more complicated than it looks. :-(
Mostly I have seen this on Times of India pages, for example: http://timesofindia.indiatimes.com/india/Sanskrit-most-useful-for-science-technology-Rajnath-Singh-says/articleshow/48641682.cms