Home › Forums › Product Support Forums › Ajax Search Pro for WordPress Support › Preload key requests performance problem
This topic contains 5 replies, has 2 voices, and was last updated by Ernest Marcinko 4 years, 2 months ago.
- AuthorPosts
- March 26, 2019 at 5:49 pm #21807
Hi, im getting following warning from google for lower perfeomnce which includes below URL that has Ajax search pro properties.
Preload key requests -1.82 s
Consider using <link rel=preload> to prioritize fetching resources that are currently requested later in page load.https://mydomain.com/wp-content/plugins/ajax-search-pro/css/fants/icons/icons2.woff2
what should i do to resolve this.please advice.
March 27, 2019 at 11:41 am #21827Hi,
That suggestion would actually decrease the page loading performance. The font is not preloaded, the browser will decide the best possible timeline to load that font file (includes only icons).
Best,
I would very highly suggest ignoring this, as preloading would actually cause a lower performance, since this font file is not high priority.
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
March 27, 2019 at 11:45 am #21830Hi Ernest,
But this Preload key requests is most time taking thing when my site loads it takes a average of -1.82 seconds.im ok to ignore it if it does only take few miliseconds .is there anyway to fix this.March 27, 2019 at 11:54 am #21835Hi,
I don’t think it takes even milliseconds, as the font file size is 2.3kb only, without gzip, with gzipped communications it’s even less. I’m not even sure it is possible to move this asset to a link tag with a preload attribute, as WordPress does not have an option to add the ‘preload’ attribute there.
Best,
I did a quick test on gtmetrix with a 60kb icon file, it took 12.2ms, so 2.3kb should take much less time to request, even less if you use cloudflare or any other CDN.
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
March 27, 2019 at 5:35 pm #21856i have attached a screenshot of google speed test .in that https://mydomain.com/wp-content/plugins/ajax-search-pro/css/fants/icons/icons2.woff2 URL is under Preload key requests which is taking 1.2 second.
also if there is no solution im Ok to have a solution that does not load icons on search bar.and only the fonts will show up.(as in my knowledge i think this happens when script try to load the search icon)
Attachments:
You must be logged in to view attached files.March 28, 2019 at 3:06 pm #21869That test shows all key requests as an estimation, in reality doing the recommended solution will more likely make the page speed slower, as the icons will be requested and rendered earlier. Unfortunately however it is not possible to move it like that, since wordpress does not support that attribute addition, so it does not really matter, the same issue would be reported either way.
You can remove this piece of code from the wp-content/plugins/ajax-search-pro/includes/classes/actions/class-asp-stylesheets.php file, from lines 109 to 126. Then clearing the cache, and it should not be there anymore. That should do the trick.
Best,
Ernest Marcinko
If you like my products, don't forget to rate them on codecanyon :)
- AuthorPosts
You must be logged in to reply to this topic.