J4 Issue ?
avatar brianteeman
brianteeman
28 Jun 2019

This code in libraries\cms\html\behavior.php is for javascript polyfills for unsupported browsers and the polyfills it links to are no longer part of joomla.

So can we just delete them and/or do we need to mark them as deprecated in J3

* Add javascript polyfills.
*
* @param string|array $polyfillTypes The polyfill type(s). Examples: event, array('event', 'classlist').
* @param string $conditionalBrowser An IE conditional expression. Example: lt IE 9 (lower than IE 9).
*
* @return void
*
* @since 3.7.0
*/

avatar brianteeman brianteeman - open - 28 Jun 2019
avatar joomla-cms-bot joomla-cms-bot - change - 28 Jun 2019
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 28 Jun 2019
avatar Bakual
Bakual - comment - 28 Jun 2019

Even when the code is useless and will not do anything, removing it could break extensions which for whatever unlikely reason have that call.
So just deprecate it in j3 and remove in 4.0.

avatar franz-wohlkoenig franz-wohlkoenig - change - 28 Jun 2019
Labels Added: J4 Issue
avatar franz-wohlkoenig franz-wohlkoenig - labeled - 28 Jun 2019
avatar mbabker
mbabker - comment - 28 Jun 2019

I'd say leave it. You're still going to have to deal with polyfills (unless you're one of those people who thinks everyone on the internet should just use a nightly build of a browser with all the latest hotness enabled), just maybe not the IE conditional browser part of it. If you remove this method now you're just going to re-add something similar when polyfills need to start being added in.

avatar brianteeman
brianteeman - comment - 28 Jun 2019

What about line 323 pointing to non existent scripts?

avatar mbabker
mbabker - comment - 28 Jun 2019

If there are no polyfills being shipped with Joomla right now, just no-op the method.

Or, someone decide "Joomla doesn't need to ship polyfills because we have a rolling browser support policy and only latest version is ever supported" (which seems to be the push, not a good thing for frontend visitors to a Joomla site) and remove anything related to supporting browser polyfills. I get the feeling the latter is going to be the path people take the way things are going around here.

avatar franz-wohlkoenig franz-wohlkoenig - change - 28 Jun 2019
Status New Discussion
avatar dgrammatiko
dgrammatiko - comment - 28 Jun 2019

Or, someone

I was that someone but the removal was only temporary till we figure out a way to fetch those polyfills (eg there weren't - I think they still aren't Joomla3 was using the polyfill.io scripts - on npmjs at the time we've moved the assets to a package.json). Pretty easy to just include core.js from https://github.com/zloirock/core-js and get anything needed in a directory, format (.js/.min.js) you want...

avatar brianteeman brianteeman - change - 6 Aug 2019
Status Discussion Closed
Closed_Date 0000-00-00 00:00:00 2019-08-06 22:22:43
Closed_By brianteeman
avatar brianteeman brianteeman - close - 6 Aug 2019

Add a Comment

Login with GitHub to post a comment