hedera-sdk-js icon indicating copy to clipboard operation
hedera-sdk-js copied to clipboard

Modernize and improve bundle size

Open kantorcodes opened this issue 2 years ago • 3 comments

Problem

At present, the bundle is a whooping 1.4 megabytes big, or 296KB.

For most modern webapps that have to stay competitive and fast, this is a huge impediment. Users are forced to download a lot of unneeded JavaScript.

5C60F757-66C2-4D8E-A91C-17933AC378F7

Solution

  • Modernize, and break out the bundle into multiple parts using tools like rollup.
  • Potentially migrate to TypeScript instead of Vanilla JS for improved type handling.

Alternatively

  • Create a "lean" version of the SDK that can cover most use cases for a frontend dApp, and a separate SDK for backend NodeJS applications.

Alternatives

No response

kantorcodes avatar Jul 14 '23 12:07 kantorcodes

Hey @kantorcodes, Thank you for your feedback. For sure we need to work in that direction. This means a lot of breaking changes. Keep in mind that such kind of changes might be implemented and included in v3 of the SDK. I will keep you updated as well about our plans and what might be done for your suggestions.

ochikov avatar Aug 02 '23 07:08 ochikov

Hey @kantorcodes, Thank you for your feedback. For sure we need to work in that direction. This means a lot of breaking changes. Keep in mind that such kind of changes might be implemented and included in v3 of the SDK. I will keep you updated as well about our plans and what might be done for your suggestions.

Thanks! Keen to hear how it goes

kantorcodes avatar Oct 30 '23 03:10 kantorcodes