Code Monkey home page Code Monkey logo

Comments (7)

elsehow avatar elsehow commented on July 26, 2024

For the libsodium.js dependency, progress is here: cosmos/cosmjs#904

For the bip39 dependency, I think we can handle that on our side with a bit better optimization. A good static analyzer should be capable of removing it. It's just a regular (i.e., js, non-compiled) dependency of cosmjs/crypto: https://github.com/cosmos/cosmjs/blob/main/packages/crypto/package.json#L47

from dao-dao-ui.

webmaster128 avatar webmaster128 commented on July 26, 2024

I wonder why libsodium.js isn't optimized out entirely. In thise codebase you use none of its functionality. However, I'm not aware of state of the art in JS optimization.

from dao-dao-ui.

elsehow avatar elsehow commented on July 26, 2024

I have the same question @webmaster128. I think whatever the next build optimizer does is just not up to snuff---reasonable tree-shaking should get rid of the dependency. (libsodium.js size is still an issue, but shouldn't be our issue).

from dao-dao-ui.

webmaster128 avatar webmaster128 commented on July 26, 2024

Jupp. I found a pretty good explanation in gcanti/fp-ts#813 and gcanti/fp-ts#814 for what needs to be done in CosmJS to make this work.

from dao-dao-ui.

JakeHartnell avatar JakeHartnell commented on July 26, 2024

I think this is a "Won't Fix" because it's upstream. Closing for now.

from dao-dao-ui.

elsehow avatar elsehow commented on July 26, 2024

Re-opening this issue, as there is some hope of trimming the bundle sizes by removing dependencies on libsodium and bip39 using the tricks described here: cosmos/cosmjs#904 (comment)

from dao-dao-ui.

ebaker avatar ebaker commented on July 26, 2024

fixed in cosmjs v0.28 - just need to upgrade the package

from dao-dao-ui.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.