feat: implement react-native-quick-bip39 ⚡️
#867
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR introduces
react-native-quick-bip39, a high-performance, lightweight, and type-safe implementation of BIP39 that leveragesreact-native-quick-cryptofor cryptographic primitives.Unlike pure JS implementations (like
bip39or@scure/bip39) which block the JS thread during seed derivation, this package offloads the heavy PBKDF2 calculation to C++ via RNQC, resulting in ~100x faster performance on mobile devices.Why a separate package?
I deliberately separated
react-native-quick-bip39from the corereact-native-quick-cryptolibrary to strictly control bundle size.react-native-quick-cryptostays a lightweight, low-level primitive library, while this package handles the higher-level BIP39 standard.Features
\u3000delimiter).docs/api/bip39.docs/guides/crypto-wallet.Changes
packages/react-native-quick-bip39containing the source, tests, and build scripts.package.jsonworkspaces.docs/content/docs/api/bip39.mdx.docs/content/docs/guides/crypto-wallet.mdxto recommend this new package.bip39todocs/content/docs/api/meta.json..gitignoreto properly ignoredocs/.next,docs/.source, anddocs/next-env.d.tsbuild artifacts.Benchmarks
Bundle Size
Verification
generateMnemonic(12 & 24 words).mnemonicToSeed(Async & Sync).bun testpasses for all test suites.