@decafhub/decaf-client-extras - v0.7.0
    Preparing search index...

    Type Alias CurrencyCode

    CurrencyCode: string & { __tag: unique symbol }

    Type definition for currency code values.

    A currency code is (typically) defined as all-uppercase, three-letter string. In this library, we are particularly using the regular expression REGEXP_CURRENCY_CODE which allows any uppercase letter followed by uppercase or lowercase letters.

    As for the type definition: We are using a (not-so-elegant) trick called "tagged-type" to annotate the plain-vanilla string type to be the CurrencyCode (poor man's newtype). Note that during the runtime, all CurrencyCode values are simply a string values.