Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Bram Doppen 3 posts 83 karma points
    Nov 25, 2021 @ 14:40
    Bram Doppen
    0

    Replace moment.js in Forms with a modern, smaller library

    Today, when running a pagespeed test on a website that uses Umbraco Forms, pagespeed insights reported some warnings about the large filesize of moment-with-locales.min.js which is used by Umbraco Forms.

    Total filesize of the minified version (moment-with-locales) is 322kb. I inspected the JavaScript really quickly and I saw the usage of moment just a few times. The filesize seems pretty huge to me to include in a plugin.

    Suggestion: Replace moment.js with some other and modern library like dayjs which uses the same syntax, is modular/tree-shakeable, and only 2kb in size.

    Happy to hear your thoughts about it!

  • [email protected] 406 posts 2135 karma points MVP 7x c-trib
    Nov 26, 2021 @ 07:09
    jeffrey@umarketingsuite.com
    100

    Hi Bram,

    welcome to the Our-forum and congratulations on your first post :)!

    🎉🎉🎉🎉🎉

    This is a great suggestion and I'm really keen on some feedback from the team that is working on Umbraco Forms. The best way to suggest this is the Github-tracker for Umbraco Forms: https://github.com/umbraco/Umbraco.Forms.Issues/issues. This is the perfect place to report bugs, request features or give great input like this!

    Hopefully you take some time to report it over there as well!

    Kindest regards,

    one of your favourite colleagues!

    Jeffrey

    enter image description here

  • iNETZO 133 posts 496 karma points c-trib
    Nov 26, 2021 @ 09:14
    iNETZO
    0

    Hi Bram,

    Like Jeffrey said: great suggestion! Please fill out the form quickly, then maybe it might be included in the upcoming version of Forms.

    Best regards,

    iNETZO

  • Bram Doppen 3 posts 83 karma points
    Nov 26, 2021 @ 14:08
    Bram Doppen
    0

    Thanks Jeffrey and iNETZO.

    I posted this issue on the Github issue tracker.

    This thread can be considered as closed.

Please Sign in or register to post replies

Write your reply to:

Draft