•  
      request #12943 Reduce size of document.js bundle
    Infos
    #12943
    Nicolas Terray (nterray)
    2019-02-05 17:29
    2019-02-01 13:28
    13819
    Details
    Reduce size of document.js bundle

    Our dependency moment-timezone includes all possible timezones with all date ranges, producing a too big document.js bundle ≃1.24 MiB.

    Ideally we should be able to load asynchronously each timezone.

    However, for a quick and short term solution I suggest to remove all dates that are after the next year (current year of the bundle generation + 1 to avoid glitches at the beginning of 2020). In document view, the only purpose of moment-timezone is to display last update date of a document (date which is in the past). There is no plan to manage dates in the future.

    By using https://github.com/gilmoreorless/moment-timezone-data-webpack-plugin, we can significantly reduce the size of the bundle.

     

    Doc/Documentation manager
    All
    Empty
    • [ ] enhancement
    • [ ] internal improvement
    Empty
    Stage
    Empty
    Closed
    2019-02-05
    Attachments
    Empty
    References
    Referencing request #12943
    Referenced by request #12943

    Artifact Tracker v5

    rel #12560 10.11

    Follow-ups

    User avatar
    Thomas Gerbet (tgerbet)2019-02-05 17:29
    Integrated into Tuleap 10.10.99.35.

    • Status changed from Under review to Closed
    • Connected artifacts
    • Close date set to 2019-02-05
    User avatar
    • Original Submission
      Something went wrong, the follow up content couldn't be loaded
      Only formatting have been changed, you should switch to markup to see the changes