[tor-bugs] #29044 [Applications/Tor Browser]: <NOSCRIPT> elements' rendering is slightly delayed (was: NoScript does not seem to disable JavaScript on loading properly)
Tor Bug Tracker & Wiki
blackhole at torproject.org
Fri Jan 11 11:07:18 UTC 2019
#29044: <NOSCRIPT> elements' rendering is slightly delayed
--------------------------------------------+--------------------------
Reporter: gk | Owner: tbb-team
Type: defect | Status: closed
Priority: Medium | Milestone:
Component: Applications/Tor Browser | Version:
Severity: Normal | Resolution: wontfix
Keywords: TorBrowserTeam201901, noscript | Actual Points:
Parent ID: | Points:
Reviewer: | Sponsor:
--------------------------------------------+--------------------------
Changes (by ma1):
* status: new => closed
* priority: Very High => Medium
* resolution: => wontfix
Comment:
That's expected, even if slightly annoying, and as noted '''no JavaScript
runs''' anyway.
NoScript 5.x, by using the available XPCOM APIs, could override the
browser's maximum priority stylesheet which enforces a
{{{
noscript {
display: none !important;
}
}}}
rule, hiding and disabling all the <NOSCRIPT> elements pre-emptively in
every docshell where JavaScript is enabled.
WebExtensions lack this overriding power, so now we must work-around with
a hack: in order to render NOSCRIPT elements on pages where NoScript 10.x
disables scripting (by using CSP, which doesn't trigger the brower's
"JavaScript disabled" HTML parsing code path),
[https://github.com/hackademix/noscript/blob/c0956b20b90e5b57ead30c783c5b102408a1190a/src/content/onScriptDisabled.js#L4
we need to replace them] with <SPAN> elements unaffected by the browser's
enforced styling '''after they're inserted in the DOM''', therefore the
delay.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/29044#comment:6>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
More information about the tor-bugs
mailing list