Tim Vereecke Posted February 9, 2019 Report Posted February 9, 2019 (edited) Hi, Background: All the banners I server are either images or HTML and there is 0% chance I serve flash. While doing a performance review of my JS code I noted the standard Revive JS code (served via /asyncjs.php) contained a whole section of JS referencing ShockwaveFlash.ShockwaveFlash Checking the asyncjs.php source I see it includes a reference to a required flash config file (fl.js in the /www/delivery folder) require __DIR__.'/'.$GLOBALS['_MAX']['CONF']['file']['asyncjsjs']; require __DIR__.'/'.$GLOBALS['_MAX']['CONF']['file']['flash']; I currently commented out the inclusion of the fl.js so the JS is smaller. All seems to work fine. Results asyncjs.php goes from 3.6KB to 2.0Kb when transferring over the wire (GZIP). (not massive, but with Chrome never slow mode, you only have a certain budget of JS available. Saving 1.6Kb here can help to stay under the 500kb limit) 9883 bytes to 42993 bytes in unzipped format. (this is less JS code to parse/execute. Read The Cost Of JavaScript In 2018 for more details https://medium.com/@addyosmani/the-cost-of-javascript-in-2018-7d8950fbb5d4) My 3 questions for the community are? Do you know any side effects of removing the fl.js inclusion? Are there better options than commenting it out? Are there other JS optimisations you are aware off? Thank you Tim Edited February 9, 2019 by scalemates Josh 1 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.