Jump to content

Polyfill: What's all this, then?


TrevMUN

Recommended Posts

2 minutes ago, NotHereToPlayGames said:

But github-wc-polyfill is not a fix-all or I would be able to pay my water bill with github-wc-polyfill added to 360Chrome v11, which I cannot, I "have to" use v13  :realmad:

Yeah, I'm not expecting it to be a silver bullet. UCyborg made that clear with the example of Web Serial API. Though, I wouldn't know right away which problems are correctable with github-wc-polyfill and which aren't.

4 minutes ago, NotHereToPlayGames said:

I was not trying to push anti-XP, I hope it didn't come across that way, I use XP on 7 of my 9 computers  :cool:

No worries, it was mainly the other guy. "(x) is old/ancient/dead" responses are a sore spot for me, especially when it's not relevant to the topic. I'd rather a clear-cut explanation of what can and can't be done with a thing rather than a lecture about how foolish it is to keep using a thing because it's old.

Link to comment
Share on other sites


3 minutes ago, TrevMUN said:

rather than a lecture about how foolish it is to keep using a thing because it's old.

Agreed!  I have a '55 Dodge with no power steering, drum brakes instead of ant-lock discs, and no seat belts.  When "safety-feature activists" lecture me on driving something without "safety features", I just snark sarcastically, "It's safety feature is NO CUP HOLDERS, she's got FOUR ash trays, but NO CUP HOLDERS.  And I don't even smoke."

Link to comment
Share on other sites

These scripts will not make you access Linkedin or any modern website. If anything, they just disable or work around some JS from the server (like the No-Script plugin). But the downside is that the website will not be completely functional for you. For example, you might need a script used by the site to post there, which your browser probably don’t support (the reason why you were after these scripts in first place).

What you are thinking to be polyfills are just user scripts, not polyfills as how I knew them. They are just user scripts and polyfills are as UCyborg described, but both things are different in terms of usage. A polyfill helps your browser to understand (to some extent) some new code like newer HTML, CSS or JS syntax and is generally (emphasis on generally, I have never heard about a client-side version) is implemented server side by the developers of these sites. Examples are Modernizr.js, and Polyfill.js (Philip Walton covers this one on his blog). A more famous polyfill for older IE was one that brought support for PNG transparency, for example.

Nowadays their usage is deprecated, since all modern browsers support these features and the websites no longer need them and no longer have to support older browsers. Pale Moon is not one of these so called modern browsers, since its a fork of an older Mozilla Firefox build.

Again, I was not being condescending about your computer or preferred browser, I was putting on facts (that you chose to ignore) about your preferred OS (XP) and browser (Pale Moon), as well as about the polyfills I knew in my career as a web developer (now Senior UI/UX Designer). They are not irrelevant, and you should take it into account if you insist on using it for serious stuff like internet banking and disclose your personal, sensitive data on websites without adequate security.

If I were being condescending, I would let you know that. I just tried to help you and you acted arrogantly as if I were just calling your computer “ancient”. No dude, we are still in 2001 (XP release) and the forked firefox version of Pale Moon is still modern and supported by Mozilla on all websites, sure! (This is me being condescending, btw).

Link to comment
Share on other sites

Also, I’m not anti XP or whatever or against old, ancient software. I just stated that for modern, daily usage, they are no longer feasible.

I also mentioned twice that I am into retro computing stuff, emulating old DOS, old macOS 9, Win 9x/XP for fun and gaming purposes. I understand why you are p***ed by the old/ancient remarks but its just the truth about these old software.

You wanted a clear, concise explanation about why you shouldn’t or cannot access sites like Linkedin or do internet banking with your “ancient” operating system and browser. I did provide that, not just calling it “ancient” and “old”.

I stated that Pale Moon is not a modern browser by any standards, is a fork of an older Mozilla Firefox not developed anymore by Mozilla itself. Therefore it means that stuff like the html/css/js rendering engine is not up to date with the current web standards, and will choke with most modern websites. But you chose to ignore it.

No client side polyfill will help you to fully navigate sites like Linkedin, Youtube, Discord or whatever Web 2.0 website you want to try. These user scripts are a different web experience and far from the normal experience in a modern browser. They are “workarounds” and most involve disabling js scripts, which is basically also disabling features of a particular website, that you might need to enjoy a proper experience surfing that website in question.

Don’t get me wrong. I would also love to drive a 1967 Mustang Fastback here. But the comparison of an old car with an old browser is not accurate. Any car will get you there as long as it has an engine working and all other basic stuff. Because the roads for them haven’t changed. A old browser will simply choke with modern websites and will not get you there. Their “roads” have changed significantly in 20 years. If it were that simple to update a browser to modern standards, I would still be using Windows 98 and Netscape (again, this is not a condescending comment) since these were my favorites back then. Unfortunately, it’s not.

To sum it up: an user script is a client side script that lets you navigate an website by (loosely) modifying parts of it to make it bearable for your old browser. They generally involve disabling JS scripts that may make your old browser choke. Not all user scripts are for old stuff (Google Chrome Extensions are a good example), some may just add features to any modern browser (like a script to resize your window for debugging responsive web design, for example).

A polyfill is a server side script that helps old browsers to understand modern language (to some extent) from html, css or js.

They are not the same thing.

Edited by Bruninho
Link to comment
Share on other sites

No disagreement from me.

I'm not trying to play both sides, so to speak, I just think both sides are correct.

However, I do not "buy into" the premise of "scare tactics" in regards to web browser "security".

I think the world does a lot of "bs" all in the name of "security" and it's all just a gigantic propaganda Love Fest frothed at the mouths of "newer is better" protagonists.

I think that anit-virus software is a "bs" industry perpetuated by "fear mongering" in the name of "security".

I've only been on MSFN for a couple years or so - but around long enough for the "regulars" to know that my stance has always been the same, unwavering.

I have always been a proponent that "safe browsing habits" trumps any "green padlock" shown in your browsers address bar.

People do a lot of "stupid stuff" and disguise that as "security".

Things like "Do Not Track Me" settings which anybody that knows anything knows is a USELESS web browser setting that does not have to be implemented at the server-side just because the client "requested" 'DNT'.

I have SIXTEEN banking sites that I use each and every day on XP and I am just as "secure" as the "newer is better" crowd visiting those SIXTEEN banking sites on resource-hungry polyfilled BLOATWARE.

 

We should all just agree to disagree.  I don't know the numbers, but the vast MAJORITY of MSFN members run XP, Vista, and 7 - not "newer is better" 10 or 11.  This web site would be "dead" without the XP crowd.

Link to comment
Share on other sites

2 hours ago, NotHereToPlayGames said:

We should all just agree to disagree.  I don't know the numbers, but the vast MAJORITY of MSFN members run XP, Vista, and 7 - not "newer is better" 10 or 11.  This web site would be "dead" without the XP crowd.

Not to mention that it's incredibly tone deaf to lecture someone who's already aware of the challenges posed by sticking with an older operating system or software.

As you observed, NotHereToPlayGames, many people here run systems with older operating systems either as a daily driver or in some other capacity. People here already know from experience that they are not going to convince developers to bend over backwards just to support their operating system. So they come to places like this forum, to RyanVM's forums, to Win-Raid and many other communities, because they're seeking potential solutions from likeminded enthusiasts. Many of whom are developers in their own right who do care and are interested in finding solutions.

That's why it's condescending to be told things like this, in this community, when asking about the potential benefits and limitations of a solution mentioned in discussions elsewhere on this site:

18 hours ago, Bruninho said:

They don't care about your old browser and they're not wrong on their side about that. They have to move forward with the path that is the Web 2.0. Don't get me wrong - this is just business for them. The world moved forward with that. Why should they care about someone using ancient browsers? Not good for their business.

Especially when, as I said earlier, it's done without actually addressing the questions posed. It comes off as if you're really saying "quit whining about your worthless ancient operating system/computer/browser, nobody has to cater to you" when no such expectations were made in the first place. Even if you didn't mean to be condescending, Bruninho, that's how the response(s) came off.

4 hours ago, Bruninho said:

If I were being condescending, I would let you know that. I just tried to help you and you acted arrogantly as if I were just calling your computer “ancient”. No dude, we are still in 2001 (XP release) and the forked firefox version of Pale Moon is still modern and supported by Mozilla on all websites, sure! (This is me being condescending, btw).

Nah, that's more like you being obnoxiously rude and sarcastic. Which, much like the attitude you've had previously, was entirely uncalled for and absolutely unhelpful.

3 hours ago, Bruninho said:

You wanted a clear, concise explanation about why you shouldn’t or cannot access sites like Linkedin or do internet banking with your “ancient” operating system and browser. I did provide that, not just calling it “ancient” and “old”.

No, you didn't. You've completely misread the room, apparently. This topic was not "why can't I access LinkedIn on these browsers," this topic was "what is Polyfill, what can it do and what can't it do." UCyborg provided a much more informative and detailed explanation as to what people were talking about in Roytam1's browsers thread, and he did so without going on about software being "ancient" and "old."

I'd say "this topic has run its course" but I'd be interested in hearing UCyborg's findings regarding the sites I mentioned.

Link to comment
Share on other sites

The current version of Pale Moon is based on Firefox 38 ESR, which was originally released in 2015. The prior release was based on Firefox 24 ESR, which was released in 2013. The project uses an older Firefox interface created before the Australis theme, and still supports XUL add-ons.

Rather than being based on Mozilla’s Gecko rendering engine, Pale Moon is based on “Goanna“, an open-source browser engine that’s a fork of gecko. Current modern firefox uses Quantum, and is on version 99 and nearly releasing version 100 in the upcoming days.

If you want to insist on using XP, at least use an official provided Mozilla option. Firefox ESR 52.6 or 58, last builds supported by XP and released by Mozilla around 2018. Its support just recently dropped.

Its not “hype and propaganda”, it’s common sense. keep your AV updated, your system updated, your browser updated, don’t click shady links, don’t accept obscure files and don’t, never ever, use an outdated browser for internet banking since its security is not up to date with the bank security measures.

A user script, what you’re confusing with a polyfill, is a client side javascript used in a browser to do things to a web page. Generally involves disabling scripts on a page to let an old browser work with it. An exception are extensions like the ones from Google Chrome, that provides extra features.

A Polyfill was a javascript thing used by me and other web developers, in the past (2001/2010) to provide old browsers like IE (main target) support for features that only existed in modern Firefox and Chrome. It was a server side thing. We as a developers don’t have to use it anymore because all modern browsers supports the features we have to use. We do not have the obligation to provide support to old (censored) like Pale Moon.

 https://www.howtogeek.com/335712/update-why-you-shouldnt-use-waterfox-pale-moon-or-basilisk/

Brazilian government and federal agencies have already switched from XP to Windows 10/11, after nearly two decades using it for its public services. Last time I worked in a federal agency they were still using Windows 7/8. XP user base in the internet is smaller than 1% right now.

If you expect to be able to continue browsing modern sites with XP, I must warn you that your expectation will be shattered. Modern web is evolving in a fast pace, even Pale Moon is failing to keep up with it, and with the rise of JS frameworks to build web sites and web apps, XP and its browsers is no longer a viable option to internet browsing. Its a fact, it’s happening right now, end period.

Edited by Tripredacus
Link to comment
Share on other sites

@TrevMUN
What browser and which version are you trying to access those sites with? Don't forget that I'm no JavaScript wizard, my JavaScript portfolio is very small. But who knows, maybe someone else comes along who may give a hint.

I have the impression polyfilling gets complicated since that extension - github-wc-polyfill - is tackling GitHub specifically. I mean if it was as simple as how it's in the script we've mentioned before, someone would've already done it, huh?

Link to comment
Share on other sites

New Moon 28 was my best shot at it. I also tried KM-Goanna; if I log into my account on LinkedIn that browser can't display anything. Pixiv's front page, logged out, does display, but not any actual pages other than that whether logged in or not.

I also have Firefox ESR 52.7.4, Chrome 49, and Advanced Chrome (Chromium 54) but none of them had any luck with these sites, and I didn't expect them to.

Link to comment
Share on other sites

1 hour ago, TrevMUN said:

New Moon 28 was my best shot at it. I also tried KM-Goanna; if I log into my account on LinkedIn that browser can't display anything. Pixiv's front page, logged out, does display, but not any actual pages other than that whether logged in or not.

I also have Firefox ESR 52.7.4, Chrome 49, and Advanced Chrome (Chromium 54) but none of them had any luck with these sites, and I didn't expect them to.

Try this: https://www.seamonkey-project.org/releases/seamonkey2.49.5/

It's what I was using on my XP virtual machines until 2020. Again, just don't use for internet banking, shopping and sensitive data. It's forked from Firefox ESR 52.9.0, newer than the ESR version you mentioned.

Link to comment
Share on other sites

Not allowing someone who disagrees with you to have the last word or let something slide is what caused this thread to get out of control.

MSFN does not have a War Room but we do have a Hurt Locker.

Edit: We can try again now

Edited by Tripredacus
Link to comment
Share on other sites

15 hours ago, TrevMUN said:

Try LinkedIn and Pixiv? Both sites have recently blanked out on me.

Pixiv presumably wants customElements in most places.

LinkedIn seems to only complain about missing PerformanceObserver when randomly clicking around. It blanks on you even on latest New Moon? Console (press F12) usually prints out an error. I don't have an account on either site.

Link to comment
Share on other sites

palefill was mentioned a while back. It's an extension based on the one fixing GitHub for Pale Moon and similar browsers (GitHub/GitLab Web Components Polyfill) and it operates on the rules that specify a website and fixes that should be applied to it. Fixes are currently hardcoded, but modifying extension shouldn't be difficult, at least for the purpose of experimenting with rules; have a copy of the XPI file, 7-Zip (or whatever you like for ZIPs) and a text editor and you can add rules in lib/main.js under const _definitions, then install modified XPI over the old one.

Pixiv has been recently added by the author. Fixes are listed in the big switch statement in the evaluateFix function in the previously mentioned main.js file.

spacer.png

Edited by UCyborg
Link to comment
Share on other sites

4 hours ago, UCyborg said:

Pixiv presumably wants customElements in most places.

LinkedIn seems to only complain about missing PerformanceObserver when randomly clicking around. It blanks on you even on latest New Moon? Console (press F12) usually prints out an error. I don't have an account on either site.

According to this page https://developer.mozilla.org/en-US/docs/Web/API/PerformanceObserver , it is only available for Firefox 57 and later. From what I have read shouldn't be something to block its usage.

I haven't found anything for customElements, but I suppose its available only from Firefox 63 and onwards. My understanding is that Pixiv is using custom HTML elements created by JS scripts to "draw" the page.

See, this is why I hate JS... *sighs*

Edited by Bruninho
Link to comment
Share on other sites

docs.microsoft.com with functional index menu on the left and no browser unsupported banner. :D Styling remains a bit off though.

spacer.png

Tricks:

palefill with the following rule added to lib/main.js:

{
  selector: ["docs.microsoft.com"],
  fix: ["std-customElements", "std-PerformanceObserver", "std-queueMicrotask"]
}

Downloaded the problematic https://docs.microsoft.com/_themes/docs.theme/master/en-us/_themes/scripts/d48a1159.index-docs.js, copied its content into Babel to cleanse it of incompatible JS syntax. Saved the output into new index-docs.js and put it somewhere under html folder of Proxomitron Reborn proxy and added the following rule to its default.cfg under HTTP Headers section:

In = FALSE
Out = TRUE
Key = "URL: Microsoft Docs (Out)"
Match = "https://docs.microsoft.com/_themes/docs.theme/master/en-us/_themes/scripts/*.index-docs.js"
Replace = "$RDIR(http://local.ptron/microsoft_docs/js/index-docs.js)"

Read local.ptron as the root of its html folder. This takes a bit of learning how to setup Proxomitron... Also no idea what's with that random string in docs JS file name (does it change name periodically?) and whether just matching whatever there is correct, the file you put through Babel once will get outdated sooner or later anyway, so then something breaks or something is even missing and you don't even know it!

Edited by UCyborg
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...