Skip to Content
Menu
This question has been flagged

After webpage tests, I see clearly the largest issue (more than first 7seconds loading time) why the mobile version is performing poorly is super large UNUSED Javascripts, and it says "Reduce unused Javascript" for the following....BUT how? 
web.assets_frontend_lazy.min.js - 924KB
en_US/base.js - 602KB
recaptcha__en.js - 162KB
www-embed-player.js - 109KB
Why odoo is serving complex Javascript files, if I am not using most of it? How to minify it, or totally not used it, OR set it to be loaded as last thing, AFTER page is rendered?
At the moment JAVASRIPTS are loading as very first files, so it creates much larger Page render time fo user as it should be.

Avatar
Discard

I'm having the same issue and trying to figure out how to remove unused js. Lighthouse and WebVitals have identified the same ...lazy.min.js file as a culprit and I can't seem to access nor edit this file. This is a huge throw off for me.

No solutions on your end as yet?

Best Answer

Though I don't know how to reduce the size, and I'm looking for the same answer, may you post the website link you are testing, and I assume you are using PageSpeed insights?


Odoo pretty much packages the entire framework in a single JS file that is already minified, and it's loaded after the page is rendered. (it uses the defer atribute). So far there is nothing we can do to reduce that file but we can look the PageSpeed reports and find if the bottleneck is somewhere else.

Avatar
Discard
Author

Hi, well different tools shows different issues : https://tools.pingdom.com/ shows the F-grade "Add Expires headers" and as E grade " Compress components with gzip"...pretty important..
Pagespeed shows best savings in:
5.6s in Reduce unused JavaScript (especially important issue for Mobile users)
2s in Reduce initial server response time
seems there is alot other details which could be done in more complex way, to speed up the user experience.....from my point of view the biggest issues are mainly the biggest delays...any ideas?

That's very strange. Odoo uses nginx server and it serves files with gzip compression by default.

As for "expire headers", they are set in all resources except in the HTML page itself. Odoo doesn't cache the html page, so everytime it is called, the qweb is rendered and it serves the html page. But the resources like css, js, images, fonts, etc, they do have expire headers.

I was curious about tools.pingdom tool, tried it against to my site and it doesn't show any result in the https version. Only on the http version and shows a 301 redirect because I forwad all http traffic to https. That tool doesn't seem to support https at all. To be honest, it looks like a terrible tool. Use another one.

As for ideas... have you already configured a CDN? That alone will improve the response speed and reduce delays. There are free ones available. Even Odoo has documentation about a particular CDN.

Related Posts Replies Views Activity
0
Apr 25
486
0
Mar 24
1158
1
Dec 23
12427
0
Feb 22
2540
0
Feb 22
2091