Reduce checkbox CE overhead
Categories
(Toolkit :: UI Widgets, defect, P3)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox86 | --- | affected |
People
(Reporter: Gijs, Unassigned)
References
(Blocks 1 open bug)
Details
See bug 1515799 comment 16 for some context.
Somehow, this 1 element in browser.xhtml accounts for up to 1ms of overhead. When I check the prefs, the overhead is smaller per item (more like 0.5ms per element, for a total of 5-10ms depending on whether I'm on Windows or macOS / fast machine vs slightly faster machine) but still noticeable. I'm guessing the improvement compared with the initial single element in browser.xhtml is due to fragment caching. Still, that's not even counting the cost we pay shortly after the load event fires and the CE overhead instrumentation runs, when the templates for the not-immediately-shown parts of the prefs get inserted.
For checkboxes, in general I'd expect us to be able to effectively use html:input type=checkbox pretty much everywhere. The downside is that we have rather a lot of them (around 125 in non-test code).
I don't know that there's much we can do to simplify this binding further to reduce the overhead, short of attempting to use CSS attr::after to insert the label, or something evil like that (but we'd lose accesskey support).
My suspicion is our best bet would be to file bugs and slowly but surely remove items until we're using HTML and can remove the binding completely.
| Reporter | ||
Updated•5 years ago
|
Updated•5 years ago
|
Description
•