Skip to content

Review dependencies to trim unused code #3

@jordaaash

Description

@jordaaash

#2 has been fixed by using Webpack's ignore plugin, but the distribution code still includes the entire bip39 dependency's API (e.g. generateMnemonic). This code is unused, but is not being caught by tree-shaking since the npm source of bip39 is JS rather than TypeScript.

The dependency graph of the build output should be analyzed and optimized to remove unused code. This could be accomplished by targeting a Github commit sha for some dependencies like bip39 to use the TS source instead of the npm published version, or extracting only the methods used, inlining them, and relying on the extended dependencies instead (in this particular case, pbkdf2).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions