Zum Inhalt springen
Odoo Menü
  • Anmelden
  • Jetzt gratis testen
  • Apps
    Finanzen
    • Buchhaltung
    • Rechnungsstellung
    • Spesenabrechnung
    • Tabellenkalkulation (BI)
    • Dokumente
    • E-Signatur
    Vertrieb
    • CRM
    • Vertrieb
    • Kassensystem – Shop
    • Kassensystem – Restaurant
    • Abonnements
    • Vermietung
    Websites
    • Website-Builder
    • E-Commerce
    • Blog
    • Forum
    • Livechat
    • E-Learning
    Lieferkette
    • Lager
    • Fertigung
    • PLM
    • Einkauf
    • Wartung
    • Qualität
    Personalwesen
    • Mitarbeiter
    • Personalbeschaffung
    • Abwesenheiten
    • Mitarbeiterbeurteilung
    • Personalempfehlungen
    • Fuhrpark
    Marketing
    • Social Marketing
    • E-Mail-Marketing
    • SMS-Marketing
    • Veranstaltungen
    • Marketing-Automatisierung
    • Umfragen
    Dienstleistungen
    • Projekte
    • Zeiterfassung
    • Außendienst
    • Kundendienst
    • Planung
    • Termine
    Produktivität
    • Dialog
    • Genehmigungen
    • IoT
    • VoIP
    • Wissensdatenbank
    • WhatsApp
    Apps von Drittanbietern Odoo Studio Odoo Cloud-Plattform
  • Branchen
    Einzelhandel
    • Buchladen
    • Kleidergeschäft
    • Möbelhaus
    • Lebensmittelgeschäft
    • Baumarkt
    • Spielwarengeschäft
    Essen & Gastgewerbe
    • Bar und Kneipe
    • Restaurant
    • Fast Food
    • Gästehaus
    • Getränkehändler
    • Hotel
    Immobilien
    • Immobilienagentur
    • Architekturbüro
    • Baugewerbe
    • Immobilienverwaltung
    • Gartenarbeit
    • Eigentümervereinigung
    Beratung
    • Buchhaltungsfirma
    • Odoo-Partner
    • Marketingagentur
    • Anwaltskanzlei
    • Talentakquise
    • Prüfung & Zertifizierung
    Fertigung
    • Textil
    • Metall
    • Möbel
    • Speisen
    • Brauerei
    • Firmengeschenke
    Gesundheit & Fitness
    • Sportklub
    • Brillengeschäft
    • Fitnessstudio
    • Therapeut
    • Apotheke
    • Friseursalon
    Handel
    • Handyman
    • IT-Hardware & -Support
    • Solarenergiesysteme
    • Schuster
    • Reinigungsdienstleistungen
    • HLK-Dienstleistungen
    Sonstiges
    • Gemeinnützige Organisation
    • Umweltschutzagentur
    • Plakatwandvermietung
    • Fotostudio
    • Fahrrad-Leasing
    • Software-Händler
    Alle Branchen ansehen
  • Community
    Lernen
    • Tutorials
    • Dokumentation
    • Zertifizierungen
    • Schulung
    • Blog
    • Podcast
    Bildung fördern
    • Bildungsprogramm
    • Scale-Up! Planspiel
    • Odoo besuchen
    Software anfragen
    • Herunterladen
    • Editionen vergleichen
    • Releases
    Zusammenarbeiten
    • Github
    • Forum
    • Veranstaltungen
    • Übersetzungen
    • Partner werden
    • Dienstleistungen für Partner
    • Buchhaltungsfirma registrieren
    Services anfragen
    • Partner finden
    • Buchhalter finden
    • Einen Experten treffen
    • Implementierungsservices
    • Kundenreferenzen
    • Support
    • Upgrades
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Eine Demo erhalten
  • Preiskalkulation
  • Hilfe

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Buchhaltung
  • Lager
  • PoS
  • Projekte
  • MRP
All apps
Sie müssen registriert sein, um mit der Community zu interagieren.
Alle Beiträge Personen Abzeichen
Stichwörter (Alle anzeigen)
odoo accounting v14 pos v15
Über dieses Forum
Sie müssen registriert sein, um mit der Community zu interagieren.
Alle Beiträge Personen Abzeichen
Stichwörter (Alle anzeigen)
odoo accounting v14 pos v15
Über dieses Forum
Hilfe

web.assets_frontend_lazy.min.js file is heavily unminified and open for lots of improvement

Abonnieren

Erhalten Sie eine Benachrichtigung, wenn es eine Aktivität zu diesem Beitrag gibt

Diese Frage wurde gekennzeichnet
pagespeedperfomance
3 Antworten
11427 Ansichten
Avatar
Juan Valencia

Hi all,

Lately I've been playing a lot with PageSpeed Insights improving the performance of my website (with Online Odoo hosting) for SEO purposes and I've come to the point where the file web.assets_frontend_lazy.min.js is the performance bottleneck.


Even though it is supposed to be minified it is heavily unminified. Around line 9787 all the way to the end line, 12278, there is a QWEB code with heavy indentation, lots of extra whitespaces and comments. Why is there a qweb template loaded into a JS variablie in a file that is supposed to be JS minified only... Anyway, the rest of the file seems properly minified with uselful comments left as title to split the code into chunks. That's good.


So, with this in mind I did a test. Downloaded that file (2.4MB !), applied a conservative minifying algorithm eliminating mostly just comments (no uglyfiyng!) and size went down to 2.25MB, and then a bit more by doing some manual whitespacing removal in my script editor for a total savings of let's round it up to 6.5% of file size. (That's a lot for just extra whitespace and comments). Then reuploaded it into the database replacing the original bundle and ran more PageSpeed tests. 

My mobile homepage was scoring around 75 with the best score at 79 with about 800ms blocking time.  I ran more tests and immediately got multiple results over 80, with the highest at 84 with a blocking time of 530ms. I conclude the results went up by 5 points in performance alone from merely removing comments and whitespace. A massive improvemet.

 

The point I want to make for the Odoo team is that further minifying that file will heavily increase performance for all users. Keep mind that the browser will stop the page rendering while downloading the brotli compressed web.assets_frontend_lazy.min.js (603kb (default) vs 571kb (modified)), uncompress it, parse the JS (bottleneck is here), execute and render the page. 

Further improvements could be made by even removing some legacy functions in that file. Also, archiving some Assets helps to reduce the JS file a bit, however, there are only about 20-30 js assets that can be archived. Way more assets need to be made accesible for end users to archive them.


Thanks!

0
Avatar
Verwerfen
Avatar
shraddha
Beste Antwort

From where I can get the lazyload assets was not able to find it got an error Uncaught promise error under the lazyload min js file but was not able to find it through developer section.

0
Avatar
Verwerfen
Avatar
Juan Valencia
Autor Beste Antwort

Hi Julien, 

Thanks for replying here and via support ticket.

Interesting, didn't know Odoo was open source. Cool. Maybe in the future I could do a PR. 

I'm using the Odoo online hosted option (enterprise). Where exactly can I find the python files mentioned in those documents? I'm searching the manifest one but can't find it. All I can find are these Assets but they are quite limited.

 

If my understading is correct, the python framework is only available to the either those hosting the open source version or the .sh plan, right? but that framework isn't available for the enterprise option as they are managed by Odoo themselves. So, coming back to the original topic of this post, that means that if I want to further improve the web.assets_frontend_lazy.min.js file, my only option is editing it after it is automatically compiled and then re uploading to the backend?

0
Avatar
Verwerfen
Avatar
Julien Launois (jula)
Beste Antwort

Hi Juan !

Here is the documentation about assets bundles https://www.odoo.com/documentation/16.0/developer/reference/frontend/assets.html

Basically every module has a manifest file where it defines which file should be in which asset bundle.

The process of retrieving the file paths to be included in those bundles is done here: https://github.com/odoo/odoo/blob/16.0/odoo/addons/base/models/ir_asset.py#L90

The minifying process is done here:

https://github.com/odoo/odoo/blob/16.0/odoo/addons/base/models/assetsbundle.py


If you have ideas about improving those processes you are more than welcome to contribute. Here is how you can do that: https://github.com/odoo/odoo/wiki/Contributing. Feel free to report some issues or even make a PR !
0
Avatar
Verwerfen
Diskutieren Sie gerne? Treten Sie bei, statt nur zu lesen!

Erstellen Sie heute ein Konto, um exklusive Funktionen zu nutzen und mit unserer tollen Community zu interagieren!

Registrieren
Verknüpfte Beiträge Antworten Ansichten Aktivität
Performace relation to image (media) files in Odoo
images perfomance odoo18 odoo17
Avatar
0
Okt. 24
1784
Which is better Odoo13 Point of Sale or Odoo14 Point of Sale?
point_of_sale Odoo13 v14 perfomance
Avatar
Avatar
1
Dez. 21
2543
Odoo.sh far too slow on mobile
performance hosting loading assets pagespeed
Avatar
0
Dez. 25
3752
Users Table takes too much time to load when having more than 100000 portal users.
postgresql optimization loading Odoo13.0 perfomance
Avatar
0
Juni 24
2119
Is it useful to use Varnish, Nginx, and ngx_pagespeed with Odoo v8? Gelöst
configuration cache nginx optimization webserver Varnish pagespeed caching vcl
Avatar
1
Mai 24
16745
Community
  • Tutorials
  • Dokumentation
  • Forum
Open Source
  • Herunterladen
  • Github
  • Runbot
  • Übersetzungen
Dienstleistungen
  • Odoo.sh-Hosting
  • Support
  • Upgrade
  • Individuelle Entwicklungen
  • Bildung
  • Buchhalter finden
  • Partner finden
  • Partner werden
Über uns
  • Unsere Firma
  • Markenwerte
  • Kontakt
  • Karriere
  • Veranstaltungen
  • Podcast
  • Blog
  • Kunden
  • Rechtliches • Datenschutz
  • Sicherheit
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo ist eine Suite von Open-Source-Betriebsanwendungen, die alle Bedürfnisse Ihres Unternehmens abdecken: CRM, E-Commerce, Buchhaltung, Lager, Kassensystem, Projektmanagement etc.

Das einzigartige Wertversprechen von Odoo ist, dass es gleichzeitig sehr einfach zu bedienen und voll integriert ist.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now