dethcrypto / dethcrypto/TypeChain

Slim down the library size

Open
#690 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
2.8k
Forks
376
PR merge metrics
No merged PRs in 30d

Description

According to https://bundlephobia.com/package/typechain@8.0.0, this lib is 558kb big (minified), which is not acceptable for consumers who want to offer a fast web experience. Additionally, not every user has an infinite amount of bandwidth available to download excessive data.

There are two dependencies that seem to cause most of the bundle size bloat:
- `prettier` is bundled as prod dep, is there a chance to make it optional or put it into devDeps? I found this related issue: https://github.com/dethcrypto/TypeChain/issues/570
- `lodash` is easy to use but makes up 20% of the bundle size of this lib, most of the methods can be easily replaced with native JS, e.g. https://github.com/you-dont-need/You-Dont-Need-Lodash-Underscore#_flatten

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.