• Demetrios Papadopoulos's avatar
    Settings WebUI: Move Settings subpages to lazy_load.html. · 8545ae68
    Demetrios Papadopoulos authored
    Move Settings subpages currently residing in the main module
    to the lazy module. This change further reduces the amount of code
    (both JS and HTML) that is part of the main module.
    
    Previously it was assumed that only elements in the "Advanced" section
    resided under the lazy_load.html module. With this change, subpages
    that are part of the basic module are also moved to lazy_load.html.
    
    The change in main_page_behavior.js is necessary to ensure that subpages
    are force loaded before we attempt to display them.
    
    Numbers from Linux build (before -> after):
    vulcanized.html           298K -> 239K, -59K, -19.8%
    crisper.js                346K -> 285K, -61K, -17.6%
    lazy_load.vulcanized.html 149K -> 207K, +58K, +38.9%
    lazy_load.crisper.js      179K -> 240K, +61K, +34.1%
    
    In this CL intentionally not touching any ChromeOS specific subpages
    (will address in follow up CL).
    
    Bug: 1026064
    Change-Id: I3b1ef541ce9d6e3a267e0b2434154c632b0b1a3e
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1922295
    Commit-Queue: Demetrios Papadopoulos <dpapad@chromium.org>
    Reviewed-by: default avatarDan Beam <dbeam@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#719484}
    8545ae68
cr_settings_browsertest.js 66.3 KB