You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm the developer of Smart Slider 3 and we use the Web Font Loader library in our code as it is important for our plugin to know when the font families used on the slider are loaded.
There are several things what prevents the proper working if Google Font Async mode enabled in Autoptimize and a slider published on the page with Smart Slider.
Web Font loader does not handle well the multiple WebFont.load calls. Only the first call's configuration parameters used.
Autopmize code always the first to run as it is placed very near to the top. Problems: both events and classes are set to false and later WebFont.load calls can not modify these options.
The Async library load placed right after the creating of the WebFontConfig, so there is no way for others to modify it. (When cache cleared, we can modify the WebFontConfig later as the async library takes some time to load up, but when it is cached there is no way to modify it.)
Possible solution to discuss
Leave the WebFontConfig in the top of the page, but move the async library load into the body, so anyone can modify the WebFontConfig object in the head.
The text was updated successfully, but these errors were encountered:
nextend
added a commit
to nextend/autoptimize
that referenced
this issue
Nov 28, 2018
I'm the developer of Smart Slider 3 and we use the Web Font Loader library in our code as it is important for our plugin to know when the font families used on the slider are loaded.
There are several things what prevents the proper working if Google Font Async mode enabled in Autoptimize and a slider published on the page with Smart Slider.
WebFont.load
calls. Only the first call's configuration parameters used.WebFont.load
calls can not modify these options.WebFontConfig
, so there is no way for others to modify it. (When cache cleared, we can modify theWebFontConfig
later as the async library takes some time to load up, but when it is cached there is no way to modify it.)Possible solution to discuss
Leave the
WebFontConfig
in the top of the page, but move the async library load into the body, so anyone can modify theWebFontConfig
object in the head.The text was updated successfully, but these errors were encountered: