Move BECH32_REGEX to nip19.ts

This commit is contained in:
Alex Gleason
2023-05-03 14:54:03 -05:00
committed by fiatjaf_
parent 977316915b
commit 1cbb62e6b9
2 changed files with 8 additions and 8 deletions

View File

@@ -5,6 +5,13 @@ import {utf8Decoder, utf8Encoder} from './utils'
const Bech32MaxSize = 5000
/**
* Bech32 regex.
* @see https://github.com/bitcoin/bips/blob/master/bip-0173.mediawiki#bech32
*/
export const BECH32_REGEX =
/[\x21-\x7E]{1,83}1[023456789acdefghjklmnpqrstuvwxyz]{6,}/
export type ProfilePointer = {
pubkey: string // hex
relays?: string[]