captcha icon indicating copy to clipboard operation
captcha copied to clipboard

ignore polkadot type wasms in bundle

Open goastler opened this issue 2 years ago • 4 comments

goastler avatar Jul 12 '23 15:07 goastler

I've read that the wasms can be missing and the polkadot types package will default back to javascript implementations. This would make the bundle smaller by quite a margin I think!

goastler avatar Jul 12 '23 15:07 goastler

sr25519 is only available via the wasm bytes.

All the wasms are chucked into a single byte array in js as a string, there's no easy way to drop specific fns, so we end up carrying around unused fns like keccak, sha512, etc.

I can't get wasm-crypto to build

They do have a rollup config suggesting you can drop some fns to reduce bundle size, but I can't get that working without a build

Could contact the guy who maintains it, iirc it's jako

goastler avatar Jul 27 '23 15:07 goastler

Or switch to something other than PolkadotJS - see ticket talking about smoldot / provider

forgetso avatar Oct 25 '23 15:10 forgetso

Bundle size isn't a blocker for us right now. Moving to low priority

HughParry avatar Jun 13 '24 20:06 HughParry

eh

HughParry avatar Sep 16 '24 20:09 HughParry