# Mnemonic

WASM implementation of Ox's BIP-39 seed derivation.

## Examples

```ts twoslash
// @noErrors
import { Engine } from 'ox'
import { Mnemonic } from 'ox/wasm'

await Engine.install({ Mnemonic: Mnemonic.engine() })

Mnemonic.toSeed(
  'test test test test test test test test test test test junk'
)
```

## Functions

| Name                | Description                         |
| ------------------- | ----------------------------------- |
| [`Mnemonic.engine`](/wasm/crypto/Mnemonic/engine) | Compiles the WASM implementation of [`Mnemonic.toSeed`](/api/Mnemonic/toSeed), without installing it. |
| [`Mnemonic.path`](/wasm/crypto/Mnemonic/path) | Creates an Ethereum-based BIP-44 HD path. |
| [`Mnemonic.random`](/wasm/crypto/Mnemonic/random) | Generates a random mnemonic. |
| [`Mnemonic.toHdKey`](/wasm/crypto/Mnemonic/toHdKey) | Converts a mnemonic to a HD Key. |
| [`Mnemonic.toPrivateKey`](/wasm/crypto/Mnemonic/toPrivateKey) | Converts a mnemonic to a private key. |
| [`Mnemonic.toSeed`](/wasm/crypto/Mnemonic/toSeed) | Converts a mnemonic to a master seed. |
| [`Mnemonic.validate`](/wasm/crypto/Mnemonic/validate) | Checks if a mnemonic is valid, given a wordlist. |

## Errors

| Name                | Description                         |
| ------------------- | ----------------------------------- |
| [`Mnemonic.MemoryError`](/wasm/crypto/Mnemonic/errors#mnemonicmemoryerror) | Thrown when a WASM module cannot grow its memory to the required size. |
