-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Metadata hash calculation #131
Comments
FWIW |
Hey @josepot, thanks a lot for the suggestion. I think it makes sense to reuse the existing community works and not to duplicate the our efforts. I've taken a look into @polkadot-api/merkleize-metadata, it's a really great work that you guys are doing there. But PAPI and Dedot are currently using different set of utilities & underlying libraries (like for scale-codec or hexToU8a conversion), so if Dedot were to ultilize this, it would result in the dapps into bundle duplicated source code for the same purpose (e.g: With that, I think we're still leaning toward having our own implementation. But we'll research and consider again when we start working on this. |
Your concerns about the
Given these numbers, it's clear that the issue is not as significant as you suggest. If the bundle size is truly a concern, please specify your target bundle size for this functionality. We can work to make it even smaller for you. As demonstrated, the total added bundle size from this library is minimal. Do you really prefer to miss out on functionality to avoid adding less than 15Kb of uncompressed JS to Dedot's bundle size? This decision seems unreasonable without evidence that your own implementation would be more size-efficient. Doesn't it make more sense to use our library initially, ensuring you have the functionality, and later, if you develop a more size-efficient solution, you can switch to your implementation? |
Hey @josepot, thanks for the bundle-size analysis. Yes agreed, for now dapps can using existing solutions provied by PAPI team or others. But we're still keeping the concerns about dapps having to bundle duplicate packages for the same purpose in mind and will revisit this later for room of optimization if needed. |
Detail: https://polkadot-fellows.github.io/RFCs/approved/0078-merkleized-metadata.html#metadata-digest
The text was updated successfully, but these errors were encountered: