logoalt Hacker News

tavisotoday at 2:05 AM1 replyview on HN

> and then the request had to wait until it was given to and processed by the blocker.

Despite the name, the requests were not blocked until the extension had initialized. The browser could make network requests before that happened with MV2. With MV3, static rulesets and persistent DNR rules are enforced immediately.

> With MV2 you'd use blocking webRequest and chrome.webRequest.onBeforeSendHenders

Of course an extensions could do this, I said uBO lite. DNR made exposing this powerful functionality fast and easy. My point is that MV3 uBO lite has useful features that MV2 uBO does not.


Replies

zamadatixtoday at 3:00 AM

> Despite the name, the requests were not blocked until the extension had initialized. The browser could make network requests before that happened with MV2. With MV3, static rulesets and persistent DNR rules are enforced immediately.

There were several workarounds like suspendTabsUntilReady which helped greatly in this half of the problem. Then it would solidly stay permanently registered too. I'm pretty sure none of these work in Chrome anymore though, it was obvious they never intended these sorts of things to work that way.

Nevertheless, MV3's ability to offer limited filtering on startup does not seem like such a blessing when the other option was to just guarantee full filtering on startup as seen in this change https://bugzilla.mozilla.org/show_bug.cgi?id=1447551

> Of course an extensions could do this, I said uBO lite. DNR made exposing this powerful functionality fast and easy. My point is that MV3 uBO lite has useful features that MV2 uBO does not.

What you said is so, it just might highlight more than what you'd like it to at the same time. That it was missing before had nothing to do with the difficulty or need for MV3. uMatrix had it for a while and Gorhill regretted it because it didn't change things like the user agent JS would report and such, hence he wouldn't port it over. The above filter has the same problems. Great if you just want a normal quality user agent switcher, that it's normal quality is why it was never in the old extension though.

show 1 reply