The [[https://github.com/jquery/jquery-ui/tree/master/demos/effect|Easing demo]] doesn't work with jQuery 1.12, 2.2, or 3.0+ (at least in Firefox 58/Chrome 64). Only the default jQuery easing values are shown - none of the additions in jQuery UI are visible. This affects the current documentation on both [[https://jqueryui.com/easing/|jqueryui.com]] and [[https://api.jqueryui.com/easings/|api.jqueryui.com]] but I have reported here because the problem is the demo itself.
The change was introduced by the new value
jQuery.easing._default in [[https://github.com/jquery/jquery/commit/5f2ea402582c7b8f4773771e1529d60587f3435e#diff-ec4583af7089881c2eeab5e54a300ef6|jQuery commit 5f2ea40]], which returns the string "swing" instead of a function. The problem is that [[https://github.com/jquery/jquery-ui/blob/c6f1735249295bb37153861aa97e5b3e38d46b02/demos/effect/easing.html#L74|Line 74]] in the demo directly executes the value
impl, without checking to see if it is a function. At this point, the script crashes both in FF and Chrome.
I can see two ways to fix it. Either check specifically for "_default" and exclude it or check to make sure impl is a function.
jsFiddle examples (these all use jQuery 1.12.1 which is the version currently used for the demo on jqueryui.com)
- [[https://jsfiddle.net/g69wpjs2/|current code (not working)]]
- [[https://jsfiddle.net/g69wpjs2/2/|specifically check for _default (working)]]
- [[https://jsfiddle.net/g69wpjs2/3/|check if impl is a function (working)]]
The only change I made in the latter two is line 11.