Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/polkadot/util-crypto/mnemonic/index.ts>mnemonicValidate

Package publishing for deno.land/x/polkadot
Go to Latest
function mnemonicValidate
import { mnemonicValidate } from "https://deno.land/x/polkadot@0.2.13/util-crypto/mnemonic/index.ts";

Examples

import { mnemonicGenerate, mnemonicValidate } from 'https://deno.land/x/polkadot@0.2.13/util-crypto/mod.ts';

const mnemonic = mnemonicGenerate(); // => string
const isValidMnemonic = mnemonicValidate(mnemonic); // => boolean

Parameters

mnemonic: string
optional
onlyJs: boolean

Returns

boolean