feat!: unite alphabet, join, padding#51
Conversation
|
note that alphabet is used here: we can probably make a specific version for bip39, if the perf benefits are really good, but backwards compat is better be good |
Can we use it when it's available and fallback when it's not? |
|
@paulmillr yes, that'll be just a few extra lines of code |
|
overall I've also searched across github and only 2 projects seem to be using |
960528f to
2e0bb3c
Compare
|
@paulmillr this would still be a semver-major though |
|
@ChALkeR radix is also non-core functionality. Can we leave bech inputs as-is? This would allow it to be released as 2.1. |
|
see this https://www.npmjs.com/package/@scure/base?activeTab=versions - i'd argue that for non-core functionality, pragmatically, we can break stuff for 1% of weekly users. "ideally" v3 would've been released for this change but it's painful to not have synced |
|
another reason not to break bech is the fact that it's using 5-bit words and NOT real uint8 stuff. |
2e0bb3c to
334cf40
Compare
|
Thanks for the speed-up. Not planned for now, but we'll re-evaluate the architecture for v3. |
Depends on:
Main:
This branch:
This can be further (significantly) optimized with TextEncoder/TextDecoder if available and not a polyfill
Also,
clocreports 519 lines of code inindex.tson this branch, but 563 in mainThis simplifies things