•  
      request #12943 Reduce size of document.js bundle
    Infos
    #12943
    Nicolas Terray (nterray)
    2019-02-05 17:29
    2019-02-01 13:28
    13144
    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.

     

    Empty
    Doc/Documentation manager
    All
    Empty
    Empty
    Stage
    Empty
    Closed
    2019-02-05
    Attachments
    Empty
    References

    List of items referenced by or referencing this item.

    Artifact Tracker v5

    Follow-ups

    • User avatar
      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
    • User avatar
      Please review gerrit #13896

      • Status changed from Under implementation to Under review